diff --git a/include/fc/thread/future.hpp b/include/fc/thread/future.hpp index 86e8a96..4c0757c 100644 --- a/include/fc/thread/future.hpp +++ b/include/fc/thread/future.hpp @@ -211,7 +211,13 @@ namespace fc { if( valid() ) { cancel(); - wait(); + try + { + wait(); + } + catch (const canceled_exception&) + { + } } } @@ -265,8 +271,14 @@ namespace fc { void cancel_and_wait() { - cancel(); - wait(); + cancel(); + try + { + wait(); + } + catch (const canceled_exception&) + { + } } /// @pre valid()