Commit 1403a0db authored by Dominik Charousset's avatar Dominik Charousset

Fix possible segfault during shutdown

A forwarding proxy sends a messages in its dtor to indicate unreferenced
proxies. However, after `kill_proxy` was called, the receiver no longer exists
and this can cause a segfault during shutdown if the message is send during the
dtor of the middleman. By redirecting all further messages after `kill_proxy`
to `invalid_actor`, we get rid of unnecessary messages as well as possible
segfaults.
parent 5e847a05
...@@ -119,6 +119,7 @@ void forwarding_actor_proxy::local_unlink_from(const actor_addr& other) { ...@@ -119,6 +119,7 @@ void forwarding_actor_proxy::local_unlink_from(const actor_addr& other) {
} }
void forwarding_actor_proxy::kill_proxy(uint32_t reason) { void forwarding_actor_proxy::kill_proxy(uint32_t reason) {
manager(invalid_actor);
cleanup(reason); cleanup(reason);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment