From db7c1345d9a12b8ffd8e04888e2a9e657d129db0 Mon Sep 17 00:00:00 2001 From: Frederic Suter Date: Mon, 8 Apr 2019 13:49:51 +0200 Subject: [PATCH] further simplify throw_exception --- src/kernel/actor/ActorImpl.cpp | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/src/kernel/actor/ActorImpl.cpp b/src/kernel/actor/ActorImpl.cpp index 5cea62caab..636f054f17 100644 --- a/src/kernel/actor/ActorImpl.cpp +++ b/src/kernel/actor/ActorImpl.cpp @@ -416,23 +416,12 @@ void ActorImpl::throw_exception(std::exception_ptr e) waiting_synchro->cancel(); activity::CommImplPtr comm = boost::dynamic_pointer_cast(waiting_synchro); - activity::SleepImplPtr sleep = boost::dynamic_pointer_cast(waiting_synchro); - if (comm != nullptr) { + if (comm != nullptr) comms.remove(comm); - } - if (sleep != nullptr) { - if (std::find(begin(simix_global->actors_to_run), end(simix_global->actors_to_run), this) == - end(simix_global->actors_to_run) && - this != SIMIX_process_self()) { - XBT_DEBUG("Inserting [%p] %s in the to_run list", this, get_cname()); - simix_global->actors_to_run.push_back(this); - } - } + waiting_synchro = nullptr; } - - waiting_synchro = nullptr; } void ActorImpl::set_host(s4u::Host* dest) -- 2.20.1