[Libreoffice-commits] online.git: loolwsd/LOOLForKit.cpp

Michael Meeks michael.meeks at collabora.com
Tue Apr 5 13:53:41 UTC 2016


 loolwsd/LOOLForKit.cpp |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 2cdc96c76d8f28a64ef0388c6673758ff58d5824
Author: Michael Meeks <michael.meeks at collabora.com>
Date:   Tue Apr 5 14:51:22 2016 +0100

    Close inherited WSD socket after fork.
    
    Leave stderr/stdout etc. though.

diff --git a/loolwsd/LOOLForKit.cpp b/loolwsd/LOOLForKit.cpp
index 84ea975..42deaff 100644
--- a/loolwsd/LOOLForKit.cpp
+++ b/loolwsd/LOOLForKit.cpp
@@ -94,6 +94,9 @@ static int createLibreOfficeKit(const std::string& childRoot,
     Process::PID pid;
     if (!(pid = fork()))
     {
+        // quicker than a generic socket closing approach.
+        close(ReaderBroker);
+
         // child
         if (std::getenv("SLEEPKITFORDEBUGGER"))
         {


More information about the Libreoffice-commits mailing list