# Close SALOME GUI
import salome_utils
-import subprocess
+import killSalomeWithPort
+
port = salome_utils.getPortNumber()
-proc = subprocess.Popen(["killSalomeWithPort.py", "{}".format(port)])
+killSalomeWithPort.killMyPort(port)
# Close SALOME GUI
import salome_utils
-import subprocess
+import killSalomeWithPort
+
port = salome_utils.getPortNumber()
-proc = subprocess.Popen(["killSalomeWithPort.py", "{}".format(port)])
+killSalomeWithPort.killMyPort(port)
def __del__(self):
port = os.getenv('NSPORT')
import killSalomeWithPort
- killSalomeWithPort.killMyPort(port)
+ if port:
+ killSalomeWithPort.killMyPort(port)
return
pass