[cig-commits] r7996 - short/3D/PyLith/trunk/libsrc/meshio

brad at geodynamics.org brad at geodynamics.org
Fri Sep 21 09:40:59 PDT 2007


Author: brad
Date: 2007-09-21 09:40:59 -0700 (Fri, 21 Sep 2007)
New Revision: 7996

Modified:
   short/3D/PyLith/trunk/libsrc/meshio/MeshIO.cc
Log:
Removed superfluous mesh->addRef(). This created an extra reference count to the mesh which prevented the undistributed mesh from being deallocated.

Modified: short/3D/PyLith/trunk/libsrc/meshio/MeshIO.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/meshio/MeshIO.cc	2007-09-20 23:25:28 UTC (rev 7995)
+++ short/3D/PyLith/trunk/libsrc/meshio/MeshIO.cc	2007-09-21 16:40:59 UTC (rev 7996)
@@ -91,7 +91,6 @@
   MPI_Bcast(&dim, 1, MPI_INT, 0, comm);
   // :BUG: This causes a memory leak.
   *_mesh = new Mesh(PETSC_COMM_WORLD, dim);
-  _mesh->addRef();
 
   assert(!_mesh->isNull());
   (*_mesh)->setDebug(_debug);



More information about the cig-commits mailing list