Boost logo

Boost Users :

Subject: Re: [Boost-users] Thread object pointers. (solved)
From: Eric J. Holtman (eric_at_[hidden])
Date: 2010-08-03 20:02:36


On 8/3/2010 4:42 PM, Albert Schueller wrote:
> Tue Aug 3 14:40:40 PDT 2010
>
> It's amazing how you stare at code for an hour, finally give up, post a
> message to a mailing list, and 5 minutes later solve the problem.
>
> The difference between the two listings is in the join()'s. In the
> first the three thread objects are created and then the three join()'s
> executed. In the second, it's thrd[0], join(), thrd[1], join(),
> thrd[2], join(). I'm not entirely sure why this matters, but it did fix
> the problem.
>
>

It matters because that's precisely what "join" is supposed
to do...... halt the calling thread until the "joined" thread is done.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net