MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / readStdin

Function readStdin

src/bitcoin-tx.cpp:756–774  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

754}
755
756static std::string readStdin()
757{
758 char buf[4096];
759 std::string ret;
760
761 while (!feof(stdin)) {
762 size_t bread = fread(buf, 1, sizeof(buf), stdin);
763 ret.append(buf, bread);
764 if (bread < sizeof(buf))
765 break;
766 }
767
768 if (ferror(stdin))
769 throw std::runtime_error("error reading stdin");
770
771 boost::algorithm::trim_right(ret);
772
773 return ret;
774}
775
776static int CommandLineRawTx(int argc, char* argv[])
777{

Callers 1

CommandLineRawTxFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected