
6 Sep
2007
6 Sep
'07
8:51 a.m.
Christopher Kohlhoff wrote:
I was traveling along this post, but now have another question: While my thread is waiting in the futures: T get() const { boost::mutex::scoped_lock lock(mutex_); while (!value_.get() && !exception_.get()) condition_.wait(lock); if (exception_.get()) exception_->raise(); return *value_; } it will not react to a io_service_.stop(); request. While I do understand why this is so, I wonder if there is a way to let the future also check for the demuxers stop flag and exit the wait by possibly throwing an error? Roland aka speedsnail