]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
More clever way to set BaseDir environment variable cge/msvc10_porting
authorCamille GOUTTEBROZE <camille.gouttebroze@cea.fr>
Fri, 5 Sep 2014 12:24:48 +0000 (14:24 +0200)
committerCamille GOUTTEBROZE <camille.gouttebroze@cea.fr>
Fri, 5 Sep 2014 12:24:48 +0000 (14:24 +0200)
bin/nameserver.py

index ce1402ba7a418b509cfb0a68937431e65aef01c4..2883701fd8bb6d3b6f99c53c2870ae6925d5ac59 100755 (executable)
@@ -25,6 +25,7 @@
 import sys, os, re, socket
 #import commands
 from server import *
+from salome_utils import getTmpDir
 from Utils_Identity import getShortHostName
 from launchConfigureParser import verbose
 
@@ -39,12 +40,7 @@ class NamingServer(Server):
    LOGDIR="/tmp/logs/" + USER
 
    def initNSArgs(self):
-        if sys.platform == "win32":
-          # temporarily using home directory for Namning Service logs
-          # to be replaced with TEMP later...
-          os.environ["BaseDir"]=os.environ["HOME"]
-        else:
-          os.environ["BaseDir"]="/tmp"
+        os.environ['BaseDir'] = getTmpDir()
 
         try:
           os.mkdir(os.environ["BaseDir"] + "/logs")