[cig-commits] r22017 - short/3D/PyLith/trunk/libsrc/pylith/faults

knepley at geodynamics.org knepley at geodynamics.org
Thu May 9 14:40:08 PDT 2013


Author: knepley
Date: 2013-05-09 14:40:08 -0700 (Thu, 09 May 2013)
New Revision: 22017

Modified:
   short/3D/PyLith/trunk/libsrc/pylith/faults/CohesiveTopology.cc
Log:
Fixed leaks

Modified: short/3D/PyLith/trunk/libsrc/pylith/faults/CohesiveTopology.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/pylith/faults/CohesiveTopology.cc	2013-05-09 20:25:38 UTC (rev 22016)
+++ short/3D/PyLith/trunk/libsrc/pylith/faults/CohesiveTopology.cc	2013-05-09 21:40:08 UTC (rev 22017)
@@ -107,6 +107,7 @@
       err = DMLabelSetValue(subpointMap, points[p], 0);PYLITH_CHECK_ERROR(err);
     }
     err = ISRestoreIndices(pointIS, &points);PYLITH_CHECK_ERROR(err);
+    err = ISDestroy(&pointIS);PYLITH_CHECK_ERROR(err);
     err = DMPlexGetDepth(faultDMMeshTmp, &depth);PYLITH_CHECK_ERROR(err);
     err = DMPlexGetDepth(faultDMMesh, &newDepth);PYLITH_CHECK_ERROR(err);
     err = DMLabelGetStratumIS(subpointMapTmp, depth, &pointIS);PYLITH_CHECK_ERROR(err);
@@ -116,7 +117,9 @@
       err = DMLabelSetValue(subpointMap, points[p], newDepth);PYLITH_CHECK_ERROR(err);
     }
     err = ISRestoreIndices(pointIS, &points);PYLITH_CHECK_ERROR(err);
+    err = ISDestroy(&pointIS);PYLITH_CHECK_ERROR(err);
     err = DMPlexSetSubpointMap(faultDMMesh, subpointMap);PYLITH_CHECK_ERROR(err);
+    err = DMLabelDestroy(&subpointMap);PYLITH_CHECK_ERROR(err);
     err = DMDestroy(&faultDMMeshTmp);PYLITH_CHECK_ERROR(err);
     if (flipFault) {
       PetscInt maxConeSize, *revcone, *revconeO;



More information about the CIG-COMMITS mailing list