This is the mail archive of the
mailing list for the pthreas-win32 project.
C++ question - string_ostream - can you help?
- To: "Pthread-List" <pthreads-win32 at sourceware dot cygnus dot com>, "Open Discussion Mailing List" <leda-discussion at postino dot mpi-sb dot mpg dot de>
- Subject: C++ question - string_ostream - can you help?
- From: "Dennis Foreman" <dforeman at stny dot rr dot com>
- Date: Sat, 15 Jul 2000 09:41:36 -0400
- Reply-To: <foreman at binghamton dot edu>
I have a function (below), that I use to (hopefully) synchronize my output
from multiple threads to a single ofstream.
Unfortunately, I am getting strange results in the output: looks like data
is being either overlayed, or the stream is not being flushed. Can you offer
void myout(string_ostream& out)
dcout<<out.str()<<flush; // debug stream file. NOT terminal I/O.
// str freezes the array!!!
D. J. Foreman