[cig-commits] r14858 - short/3D/PyLith/branches/pylith-swig/libsrc/topology
brad at geodynamics.org
brad at geodynamics.org
Mon May 4 14:35:01 PDT 2009
Author: brad
Date: 2009-05-04 14:35:00 -0700 (Mon, 04 May 2009)
New Revision: 14858
Modified:
short/3D/PyLith/branches/pylith-swig/libsrc/topology/Mesh.cc
short/3D/PyLith/branches/pylith-swig/libsrc/topology/SubMesh.cc
Log:
Fixed bug related to initialization of coordinate system for Mesh and SubMesh.
Modified: short/3D/PyLith/branches/pylith-swig/libsrc/topology/Mesh.cc
===================================================================
--- short/3D/PyLith/branches/pylith-swig/libsrc/topology/Mesh.cc 2009-05-04 21:27:02 UTC (rev 14857)
+++ short/3D/PyLith/branches/pylith-swig/libsrc/topology/Mesh.cc 2009-05-04 21:35:00 UTC (rev 14858)
@@ -63,6 +63,8 @@
pylith::topology::Mesh::coordsys(const spatialdata::geocoords::CoordSys* cs)
{ // coordsys
delete _coordsys; _coordsys = (0 != cs) ? cs->clone() : 0;
+ if (0 != _coordsys)
+ _coordsys->initialize();
} // coordsys
// ----------------------------------------------------------------------
@@ -70,8 +72,6 @@
void
pylith::topology::Mesh::initialize(void)
{ // initialize
- if (0 != _coordsys)
- _coordsys->initialize();
} // initialize
Modified: short/3D/PyLith/branches/pylith-swig/libsrc/topology/SubMesh.cc
===================================================================
--- short/3D/PyLith/branches/pylith-swig/libsrc/topology/SubMesh.cc 2009-05-04 21:27:02 UTC (rev 14857)
+++ short/3D/PyLith/branches/pylith-swig/libsrc/topology/SubMesh.cc 2009-05-04 21:35:00 UTC (rev 14858)
@@ -117,8 +117,11 @@
{ // coordsys
delete _coordsys; _coordsys = 0;
const spatialdata::geocoords::CoordSys* cs = mesh.coordsys();
- if (0 != cs)
+ if (0 != cs) {
_coordsys = cs->clone();
+ assert(0 != _coordsys);
+ _coordsys->initialize();
+ } // if
} // coordsys
// ----------------------------------------------------------------------
More information about the CIG-COMMITS
mailing list