Added istream_read() function.