diff --git a/examples/streaming.cc b/examples/streaming.cc index 1baf75a..52a7db2 100644 --- a/examples/streaming.cc +++ b/examples/streaming.cc @@ -64,7 +64,7 @@ int main(void) { root_context ctx; std::string err; - picojson::_parse(ctx, std::istream_iterator(std::cin), std::istream_iterator(), &err); + picojson::_parse(ctx, std::istreambuf_iterator(std::cin), std::istreambuf_iterator(), &err); if (!err.empty()) { std::cerr << err << std::endl;