moved the delete to after the data is used
@@ -555,9 +555,6 @@ avtPersistentParticlesFilter::IterateTraceData(int ts, avtDataTree_p tree)
if (nds == 0)
haveData = false;
- // Free the memory from the GetAllLeaves function call.
- delete [] dsets;
-
vtkDataSet *currDs = 0;
vtkPointSet *uGrid = 0;
vtkPoints *currPoints = 0;
@@ -647,6 +644,9 @@ avtPersistentParticlesFilter::IterateTraceData(int ts, avtDataTree_p tree)
}
}
+ // Free the memory from the GetAllLeaves function call.
+ delete [] dsets;
+
// Parallel
// Points can be scattered across ranks and there is no gaurantee
