id summary reporter owner description type status milestone component version severity resolution keywords cc 10056 boost::promise runs arbitrary code while holding mutex lock Jonathan Wakely viboes "This deadlocks or aborts, depending on how pthreads handles re-locking a mutex in the same thread: {{{ #include struct X { X() { } X(const X&); }; boost::unique_future fut; X::X(const X&) { fut.wait_for(boost::chrono::milliseconds(1)); } int main() { boost::promise p; fut = p.get_future(); p.set_value( X() ); } }}} promise::set_value() owns a lock while invoking the copy constructor, which might have side-effects." Bugs closed thread Boost 1.54.0 Problem wontfix