Salome HOME
Fixed problem with dump study and small optimization:
[modules/kernel.git] / bin / runConsole.py
index 337b1eb94da0ea5d8d21f74d3491466399d7ea41..718321094be914617d1054ee1a8f3c49bf80452a 100644 (file)
@@ -1,5 +1,5 @@
 #  -*- coding: iso-8859-1 -*-
-# Copyright (C) 2007-2015  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2007-2016  CEA/DEN, EDF R&D, OPEN CASCADE
 #
 # Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -103,7 +103,7 @@ def __get_running_session(requested_port=None, lastInstanceByDefault=False):
   host, port, filename = None, None, None
   if requested_port:
     print "Search for running instance on port %s..."%requested_port
-    found = [(h,p,f) for h,p,f in available_connexions if p == requested_port]
+    found = [(h,p,f) for h,p,f in available_connexions if int(p) == int(requested_port)]
     if not found:
       print "   ...no running instance found"
     elif len(found) == 1:
@@ -150,8 +150,6 @@ class client(orbmodule.client):
 #
 
 def start_client():
-  print os.getenv("OMNIORB_CONFIG")
-
   try:
     clt = client()
   except Exception:
@@ -164,7 +162,7 @@ def start_client():
   if session_server:
     session = clt.waitNS("/Kernel/Session")
   catalog = clt.waitNS("/Kernel/ModulCatalog")
-  studyMgr = clt.waitNS("/myStudyManager")
+  study = clt.waitNS("/Study")
 
   import salome
   salome.salome_init()