[Libreoffice-commits] .: l10ntools/source

Ivan Timofeev ivantimofeev at kemper.freedesktop.org
Mon Aug 6 23:10:14 PDT 2012


 l10ntools/source/help/HelpCompiler.cxx |    9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

New commits:
commit a9210660294dd40c18814f59106164d548416032
Author: Ivan Timofeev <timofeev.i.s at gmail.com>
Date:   Tue Aug 7 10:06:04 2012 +0400

    fix crash on start
    
    Change-Id: Ieee907d38711761f4770b802f54bd38c4e807807

diff --git a/l10ntools/source/help/HelpCompiler.cxx b/l10ntools/source/help/HelpCompiler.cxx
index e28ac92..2a5fda5 100644
--- a/l10ntools/source/help/HelpCompiler.cxx
+++ b/l10ntools/source/help/HelpCompiler.cxx
@@ -55,9 +55,12 @@ HelpCompiler::HelpCompiler(StreamTable &in_streamTable, const fs::path &in_input
 {
     xmlKeepBlanksDefaultValue = 0;
     char* guitmp = getenv("GUI");
-    gui = (strcmp(guitmp, "UNX") ? gui : "UNIX");
-    gui = (strcmp(guitmp, "MAC") ? gui : "MAC");
-    gui = (strcmp(guitmp, "WNT") ? gui : "WIN");
+    if (guitmp)
+    {
+        gui = (strcmp(guitmp, "UNX") ? gui : "UNIX");
+        gui = (strcmp(guitmp, "MAC") ? gui : "MAC");
+        gui = (strcmp(guitmp, "WNT") ? gui : "WIN");
+    }
 }
 
 xmlDocPtr HelpCompiler::getSourceDocument(const fs::path &filePath)


More information about the Libreoffice-commits mailing list