
I've added a new version to boost vault - it should fix the problem. Oliver Am Dienstag 25 August 2009 11:48:11 schrieb Harald Winroth:
I wrote a short test program to check that each copy construction of a functor passed to a boost::task::task and boost::task::async was balanced by a corresponding destructor call. This is indeed the case when the task is run in a thread pool but it seems as if one destructor call is missing when the task is submitted to to boost::task::async with a boost::task::new_thread execution policy.
Here is the a short test program and the resulting output. For comparison, the same functor is also passed directly to a boost::thread, which behaves as expected. The program was compiled using Visual C++ 2005 (SP1), and boost 1.39.0 with the latest Boost.Task library from the vault dropped in.
Any ideas? Am I missing something?
Best regards Harald