From ec2492b4748c7f013c4852f7743ab8707a70ca18 Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Wed, 24 Apr 2019 14:09:23 +0200 Subject: [PATCH 1/1] Clear the 'on_exit' vector when the actor doesn't have to restart. The python tests actor-kill and actor-daemon were failing. --- src/kernel/actor/ActorImpl.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/kernel/actor/ActorImpl.cpp b/src/kernel/actor/ActorImpl.cpp index 86b8b59eff..aec21aae32 100644 --- a/src/kernel/actor/ActorImpl.cpp +++ b/src/kernel/actor/ActorImpl.cpp @@ -143,6 +143,8 @@ void ActorImpl::cleanup() bool failed = context_->iwannadie; for (auto exit_fun = on_exit->crbegin(); exit_fun != on_exit->crend(); ++exit_fun) (*exit_fun)(failed); + if (not has_to_auto_restart()) + on_exit->clear(); /* cancel non-blocking activities */ for (auto activity : comms) -- 2.20.1