From 69d9f23342450bb2daa1a180f817ae1e5460d508 Mon Sep 17 00:00:00 2001 From: mpv Date: Wed, 8 Jun 2005 06:49:55 +0000 Subject: [PATCH] Fixing of PAL9090 bug: save Serser's pids not to the "/tmp" directory, but to the ${HOME} directory. --- bin/killSalome.py | 2 +- bin/killSalomeWithPort.py | 2 +- bin/runSalome.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/killSalome.py b/bin/killSalome.py index 96e923980..7ed1d6372 100755 --- a/bin/killSalome.py +++ b/bin/killSalome.py @@ -5,7 +5,7 @@ from killSalomeWithPort import killMyPort def killAllPorts(): user = os.getenv('USER') - for file in os.listdir("/tmp"): + for file in os.listdir(os.getenv("HOME")): l = string.split(file, "_") if len(l) >= 4: if file[:len(user)] == user: diff --git a/bin/killSalomeWithPort.py b/bin/killSalomeWithPort.py index 7c8dcd2ed..bf02709cf 100755 --- a/bin/killSalomeWithPort.py +++ b/bin/killSalomeWithPort.py @@ -3,7 +3,7 @@ import os, sys, pickle, signal, commands ########## kills all salome processes with the given port ########## def killMyPort(port): - filedict='/tmp/'+os.getenv('USER')+"_"+port+'_SALOME_pidict' + filedict=os.getenv("HOME")+'/'+os.getenv('USER')+"_"+port+'_SALOME_pidict' found = 0 try: fpid=open(filedict, 'r') diff --git a/bin/runSalome.py b/bin/runSalome.py index 055268c56..a9bd92370 100755 --- a/bin/runSalome.py +++ b/bin/runSalome.py @@ -674,7 +674,7 @@ def useSalome(args, modules_list, modules_root_dir): #print process_id - filedict = '/tmp/' + os.getenv('USER') + "_" + str(args['port']) \ + filedict = os.getenv("HOME") + '/' + os.getenv('USER') + "_" + str(args['port']) \ + '_' + args['appname'].upper() + '_pidict' process_ids = [] -- 2.39.2