mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-15 00:20:35 +05:00
prevent GetName() failure on a not CORBA object
This commit is contained in:
parent
a763cfdd81
commit
d7b0855638
@ -186,7 +186,10 @@ def GetName(obj):
|
||||
if isinstance(obj, SALOMEDS._objref_SObject):
|
||||
# study object
|
||||
return obj.GetName()
|
||||
ior = salome.orb.object_to_string(obj)
|
||||
try:
|
||||
ior = salome.orb.object_to_string(obj)
|
||||
except:
|
||||
ior = None
|
||||
if ior:
|
||||
# CORBA object
|
||||
studies = salome.myStudyManager.GetOpenStudies()
|
||||
|
Loading…
Reference in New Issue
Block a user