Salome HOME
projects
/
modules
/
smesh.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
fdfe9f0
)
fix bug 12361. In SetName(): there may be no study
author
eap
<eap@opencascade.com>
Wed, 10 May 2006 12:54:55 +0000
(12:54 +0000)
committer
eap
<eap@opencascade.com>
Wed, 10 May 2006 12:54:55 +0000
(12:54 +0000)
src/SMESH_SWIG/smesh.py
patch
|
blob
|
history
diff --git
a/src/SMESH_SWIG/smesh.py
b/src/SMESH_SWIG/smesh.py
index bf7fed0117ea63d8c442c7a12fe32bef6b2def19..6b95891c7b07192fd00a02938010890048c4ab08 100644
(file)
--- a/
src/SMESH_SWIG/smesh.py
+++ b/
src/SMESH_SWIG/smesh.py
@@
-60,8
+60,9
@@
def GetName(obj):
def SetName(obj, name):
ior = salome.orb.object_to_string(obj)
sobj = salome.myStudy.FindObjectIOR(ior)
- attr = sobj.FindAttribute("AttributeName")[1]
- attr.SetValue(name)
+ if not sobj is None:
+ attr = sobj.FindAttribute("AttributeName")[1]
+ attr.SetValue(name)
# Algorithms and hypothesis
# =========================