----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/55701/ -----------------------------------------------------------
Review request for mesos, Benjamin Bannier, Benjamin Hindman, Benjamin Mahler, and Michael Park. Repository: mesos Description ------- The `async(...)` helper spawns a libprocess actor to execute some lambda (asynchronously, of course). This actor is owned by the libprocess GC actor, but the `AsyncExecutor` stores a copy of that pointer and dereferences it in several possible locations. Instead, the `AsyncExecutor` should store the `PID` of the actor, which can be safely used, even if the actor has already terminated; such as turning libprocess finalization. Diffs ----- 3rdparty/libprocess/include/process/async.hpp 8565a52c6ba4008edb852e898b8f0b6d598a194f Diff: https://reviews.apache.org/r/55701/diff/ Testing ------- Applied the following change: ``` diff --git a/src/launcher/executor.cpp b/src/launcher/executor.cpp index e035a4e..4c60ef9 100644 --- a/src/launcher/executor.cpp +++ b/src/launcher/executor.cpp @@ -936,6 +930,8 @@ int main(int argc, char** argv) process::spawn(executor.get()); process::wait(executor.get()); + executor.reset(); + process::finalize(true); return EXIT_SUCCESS; } ``` And then ran: ``` make check GTEST_FILTER="HTTPCommandExecutorTest.TerminateWithACK" ``` Thanks, Joseph Wu
