"Ben Hutchings"
That still won't solve your problem, in general. Multithreading is an / ... / You should protect all access to the controlling flag with a mutex. In this case it would probably be sufficient to use the "volatile" qualifier on the controlling member, but this is not generally a good solution. Ben.
In this case, I think the problem was that by {mis,ab,}using the boost thread lib, I passed a copy of the functor that would be the worker thread instead of just a reference to it, hence the duplicity. Protecting that variable with a mutex wouldn't have had any effect, since there would have been two copies still. regards... Dan --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.806 / Virus Database: 548 - Release Date: 05-Dec-04