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

Mihai Varga mihai.varga at collabora.com
Fri Sep 4 08:44:46 PDT 2015


 loolwsd/LOOLWSD.cpp |    6 ++++++
 1 file changed, 6 insertions(+)

New commits:
commit 515e6f7feaf7587300bbb399b19aba791c37f503
Author: Mihai Varga <mihai.varga at collabora.com>
Date:   Fri Sep 4 18:43:47 2015 +0300

    loolwsd: copy /etc/resolv.conf in the jail
    
    Because sometimes the hostname is not resolved

diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 798428c..33fa261 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -894,6 +894,12 @@ void LOOLWSD::desktopMain()
     linkOrCopy(LOOLWSD::sysTemplate, jail);
     linkOrCopy(LOOLWSD::loTemplate, jailLOInstallation);
 
+    // We need this because sometimes the hostname is not resolved
+    File resolv("/etc/resolv.conf");
+    if (resolv.exists())
+    {
+        resolv.copyTo(Path(jail, "/etc").toString());
+    }
 #ifdef __linux
     // Create the urandom and random devices
     File(Path(jail, "/dev")).createDirectory();


More information about the Libreoffice-commits mailing list