From: jfa Date: Tue, 13 Dec 2005 14:34:32 +0000 (+0000) Subject: PAL10873: Debian: HOSTNAME settings. Update fix in accordance with modifications... X-Git-Tag: T_2_2_7pre2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=8956548ae5ee578fb95319f45cc72d69390c859d;p=modules%2Fkernel.git PAL10873: Debian: HOSTNAME settings. Update fix in accordance with modifications in HEAD. --- diff --git a/bin/killSalomeWithPort.py b/bin/killSalomeWithPort.py index bb71dc2f6..951b66bb6 100755 --- a/bin/killSalomeWithPort.py +++ b/bin/killSalomeWithPort.py @@ -4,15 +4,15 @@ import os, sys, pickle, signal, commands def getPiDict(port,appname='salome',full=True): from Utils_Identity import getShortHostName - if os.getenv("HOSTNAME") == None: - if os.getenv("HOST") == None: - os.environ["HOSTNAME"]=getShortHostName() - else: - os.environ["HOSTNAME"]=os.getenv("HOST") + host = os.getenv("HOSTNAME") + if not host: + host = os.getenv("HOST") + if not host: + host = getShortHostName() filedict = [] filedict.append( os.getenv('USER') ) # user name - filedict.append( os.getenv('HOSTNAME') ) # host name + filedict.append( host ) # host name filedict.append( str(port) ) # port number filedict.append( appname.upper() ) # application name filedict.append( 'pidict' ) # constant part