On Mon, Mar 26, 2012 at 9:17 AM, Arno
<arno.schaefer@sqs.de> wrote:
> boost::this_thread::sleep(boost::get_system_time()+
> boost::posix_time::milliseconds(millisec_));
Hi Ovanes,
I took my call from examples what I have found and use it at many places in
our code and til now it seems to work correctly.
Our problem is not related to the use of sleep, I look for reasons what can
happen, that a thread stops without any known reason.
Do you have some hints in this direction?
Arno,
if that is not the reason, I would run it in the debugger and enable the debugger to stop whenever an exception is thrown or a signal is raised. Try to see if that happens when this one thread runs... Logs might help as well. Finally, does the program wait for the thread to exit or does it detaches the thread from the thread object? Is is possible that some dangling references or pointers are accessed in the thread (but than the debugger should receive an access violation signal).
Can you reproduce a minimal example to be posted here. I know it might be hard to do when dealing with MT-contexts.
Best Regards,
Ovanes