Skip to content
Snippets Groups Projects
Commit 5e4d7ec7 authored by Monroe Linden's avatar Monroe Linden
Browse files

In LLPluginProcessParent, instead of killing the plugin process, terminate it...

In LLPluginProcessParent, instead of killing the plugin process, terminate it by closing the sockets.  This lets it do some cleanup before exiting, instead of just getting shot.
parent 6245ae0b
No related branches found
No related tags found
No related merge requests found
...@@ -79,8 +79,10 @@ LLPluginProcessParent::~LLPluginProcessParent() ...@@ -79,8 +79,10 @@ LLPluginProcessParent::~LLPluginProcessParent()
// and remove it from our map // and remove it from our map
mSharedMemoryRegions.erase(iter); mSharedMemoryRegions.erase(iter);
} }
mProcess.kill(); // orphaning the process means it won't be killed when the LLProcessLauncher is destructed.
// This is what we want -- it should exit cleanly once it notices the sockets have been closed.
mProcess.orphan();
killSockets(); killSockets();
} }
...@@ -414,7 +416,8 @@ void LLPluginProcessParent::idle(void) ...@@ -414,7 +416,8 @@ void LLPluginProcessParent::idle(void)
break; break;
case STATE_CLEANUP: case STATE_CLEANUP:
mProcess.kill(); // Don't do a kill here anymore -- closing the sockets is the new 'kill'.
mProcess.orphan();
killSockets(); killSockets();
setState(STATE_DONE); setState(STATE_DONE);
break; break;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment