Serializing access to Streams—Marco Foco

Save to:
Instapaper Pocket Readability

A new blog post containing runnable code from the Italian C++ Community:

Serializing access to Streams

by Marco Foco

From the article:

Two or more threads were writing to cout using the form:

cout << someData << "some string" << someObject << endl;

And one of the problems was that data sent from one thread often interrupted another thread, so the output was always messed up. [...] I started designing a solution by giving myself some guidelines, here listed in order of importance...

Add a Comment

You must sign in or register to add a comment.

Comments (0)

There are currently no comments on this entry.