Skip to content

Commit

Permalink
Merge pull request #202 from mgignac/mgignac-memory-mgnt-1
Browse files Browse the repository at this point in the history
Clean-up memory
  • Loading branch information
mgignac authored Jan 6, 2025
2 parents 9c1baff + 35cf82e commit 4170f3d
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions processors/src/FinalStateParticleProcessor.cxx
Original file line number Diff line number Diff line change
@@ -148,6 +148,7 @@ bool FinalStateParticleProcessor::process(IEvent* ievent) {
// loop on j>i tracks
}
fsp->setTrack(track);
delete track;
}

if (debug_ > 0) std::cout << "FinalStateParticleProcessor: Add Particle" << std::endl;
6 changes: 5 additions & 1 deletion processors/src/VertexProcessor.cxx
Original file line number Diff line number Diff line change
@@ -195,11 +195,15 @@ bool VertexProcessor::process(IEvent* ievent) {

track->addHitLayer(hitLayer);
hits_.push_back(tracker_hit);
rawSvthitsOn3d.clear();
for (std::vector<RawSvtHit *>::iterator it = rawSvthitsOn3d.begin(); it != rawSvthitsOn3d.end(); ++it) {
delete *it;
}
rawSvthitsOn3d.clear();
// loop on j>i tracks
}
track->setTrackerHitCount(nHits);
part->setTrack(track);
delete track;
}
//=============================================
if (debug_ > 0) std::cout << "VertexProcessor: Add particle" << std::endl;

0 comments on commit 4170f3d

Please sign in to comment.