
Hi all, I try to use memory map file. However, I don't know why the readsome return 0. It is fine if I use getline. int main(int argc,char *argv[]) { boost::iostreams::mapped_file_source source(argv[1]); boost::iostreams::stream<boost::iostreams::mapped_file_source> input(source); while(!input.eof()) { char b[1]; streamsize iRet = input.readsome(b, 1); cout << iRet << endl; cout << b[iRet]; } //std::string line; //while(std::getline(input, line)) { // std::cout << "Line: " << line << std::endl; //} return 1; } -- View this message in context: http://boost.2283326.n4.nabble.com/boost-mapped-file-issue-tp3971495p3971495... Sent from the Boost - Dev mailing list archive at Nabble.com.