|
Boost Users : |
Subject: Re: [Boost-users] [boost::thread] interrupt a future get boost::unknown_exception
From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2011-03-18 14:32:41
On Fri, Mar 18, 2011 at 3:30 AM, ä¹å¿å¼º <qiaozhiqiang_at_[hidden]> wrote:
> [Windows XP, VC++ 10, boost 1.46]
> When interrupt a future, the future.get() throw boost::unknown_exception,
> Not boost::thread_interrupted.
>
> Class boost::thread_interrupted should have a base class for current_exception_impl() to catch it ? or use BOOST_THROW_EXCEPTION in interruptible_wait) ?
As far as I can tell, boost::thread always throws by calling
boost::throw_exception which is sufficient for the
boost::exception_ptr framework to work. Most likely, the
unknown_exception is a result of attempting to copy a non-boost
exception.
Emil Dotchevski
Reverge Studios, Inc.
http://www.revergestudios.com/reblog/index.php?n=ReCode
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net