Write a binary stream (cannot output to a string)
std::string s(record.data.buf(), record.data.size());
ofstream file1;
file1.open ("/tmp/kalyan",ios::binary);
file1.write(bytebuffer, size);
file1.close();
std::string s(record.data.buf(), record.data.size());
ofstream file1;
file1.open ("/tmp/kalyan",ios::binary);
file1.write(bytebuffer, size);
file1.close();
Posted by kalyan at 3:56 PM
Labels: c++ streams
Post a Comment