loleaflet/spec/data/lorem.odt             |binary
 loleaflet/spec/loleaflet/loleafletSpec.js |    5 ++++-
 loleaflet/spec/tilebench/TileBenchSpec.js |    5 ++++-
 loolwsd/LOOLWSD.cpp                       |   15 +++++++--------
 loolwsd/loolwsd-systemplate-setup         |    2 ++
 5 files changed, 17 insertions(+), 10 deletions(-)

New commits:
commit 76304bbd379033e683f53cfc50c8cb906fe3d91b
Author: Mihai Varga <mihai.va...@collabora.com>
Date:   Tue Sep 8 13:03:43 2015 +0300

    loolwsd: copy /etc/localtime when running systemplate-setup

diff --git a/loolwsd/loolwsd-systemplate-setup 
b/loolwsd/loolwsd-systemplate-setup
index 3d18283..f501ae0 100755
--- a/loolwsd/loolwsd-systemplate-setup
+++ b/loolwsd/loolwsd-systemplate-setup
@@ -30,6 +30,8 @@ cd / || exit 1
             lib/libnss_* lib64/libnss_* \
             var/cache/fontconfig \
             etc/fonts \
+            etc/localtime \
+            usr/share/zoneinfo/* \
             usr/share/liblangtag \
             lib/*-linux-gnu/libnss* \
                 -type f
commit e3951886287de774ae37689c0eaedde0e8eede8e
Author: Mihai Varga <mihai.va...@collabora.com>
Date:   Tue Sep 8 13:03:14 2015 +0300

    loolwsd: also add /etc/host.conf in chroot

diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 76bb8cf..d0acb7b 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -864,7 +864,7 @@ void LOOLWSD::desktopMain()
     linkOrCopy(LOOLWSD::loTemplate, jailLOInstallation);
 
     // We need this because sometimes the hostname is not resolved
-    std::vector<std::string> networkFiles = {"/etc/hosts", 
"/etc/nsswitch.conf", "/etc/resolv.conf"};
+    std::vector<std::string> networkFiles = {"/etc/host.conf", "/etc/hosts", 
"/etc/nsswitch.conf", "/etc/resolv.conf"};
     for (std::vector<std::string>::iterator it = networkFiles.begin(); it != 
networkFiles.end(); ++it)
     {
         File networkFile(*it);
commit 96bb22241de099c9a750b2d6c3e93457b63077a2
Author: Mihai Varga <mihai.va...@collabora.com>
Date:   Tue Sep 8 12:01:59 2015 +0300

    loleaflet: test document

diff --git a/loleaflet/spec/data/lorem.odt b/loleaflet/spec/data/lorem.odt
new file mode 100644
index 0000000..1b26ee1
Binary files /dev/null and b/loleaflet/spec/data/lorem.odt differ
diff --git a/loleaflet/spec/loleaflet/loleafletSpec.js 
b/loleaflet/spec/loleaflet/loleafletSpec.js
index fd16985..dd8fe14 100644
--- a/loleaflet/spec/loleaflet/loleafletSpec.js
+++ b/loleaflet/spec/loleaflet/loleafletSpec.js
@@ -13,10 +13,13 @@ describe('TileBench', function () {
        }
 
        before(function () {
+               var htmlPath = window.location.pathname;
+               var dir = htmlPath.substring(0, htmlPath.lastIndexOf('/'));
+               var fileURL = 'file://' + dir + '/data/lorem.odt';
                // initialize the map and load the document
                map = L.map('map', {
                        server: 'ws://localhost:9980',
-                       doc: 'file:///home/mihai/Desktop/test_docs/eval.odt',
+                       doc: fileURL,
                        edit: false,
                        readOnly: false
                });
diff --git a/loleaflet/spec/tilebench/TileBenchSpec.js 
b/loleaflet/spec/tilebench/TileBenchSpec.js
index 7fb85de..f3882a0 100644
--- a/loleaflet/spec/tilebench/TileBenchSpec.js
+++ b/loleaflet/spec/tilebench/TileBenchSpec.js
@@ -14,10 +14,13 @@ describe('TileBench', function () {
        }
 
        before(function () {
+               var htmlPath = window.location.pathname;
+               var dir = htmlPath.substring(0, htmlPath.lastIndexOf('/'));
+               var fileURL = 'file://' + dir + '/data/lorem.odt';
                // initialize the map and load the document
                map = L.map('map', {
                        server: 'ws://localhost:9980',
-                       doc: 'file:///home/mihai/Desktop/test_docs/eval.odt',
+                       doc: fileURL,
                        edit: false,
                        readOnly: false
                });
commit e80da7a5848806951a1fb781d39e3a1015d2e2f5
Author: Mihai Varga <mihai.va...@collabora.com>
Date:   Tue Sep 8 11:31:49 2015 +0300

    loolwsd: also copy /etc/nsswitch.conf

diff --git a/loolwsd/LOOLWSD.cpp b/loolwsd/LOOLWSD.cpp
index 8e76a80..76bb8cf 100644
--- a/loolwsd/LOOLWSD.cpp
+++ b/loolwsd/LOOLWSD.cpp
@@ -864,15 +864,14 @@ void LOOLWSD::desktopMain()
     linkOrCopy(LOOLWSD::loTemplate, jailLOInstallation);
 
     // We need this because sometimes the hostname is not resolved
-    File resolv("/etc/resolv.conf");
-    if (resolv.exists())
+    std::vector<std::string> networkFiles = {"/etc/hosts", 
"/etc/nsswitch.conf", "/etc/resolv.conf"};
+    for (std::vector<std::string>::iterator it = networkFiles.begin(); it != 
networkFiles.end(); ++it)
     {
-        resolv.copyTo(Path(jail, "/etc").toString());
-    }
-    File hosts("/etc/hosts");
-    if (hosts.exists())
-    {
-        hosts.copyTo(Path(jail, "/etc").toString());
+        File networkFile(*it);
+        if (networkFile.exists())
+        {
+            networkFile.copyTo(Path(jail, "/etc").toString());
+        }
     }
 #ifdef __linux
     // Create the urandom and random devices
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to