Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix memory leaks in FastTSGFromPropagation #8663

Merged

Conversation

wmtan
Copy link
Contributor

@wmtan wmtan commented Apr 3, 2015

While adding the consumes interface in 7_5_X to class FastTSGFromPropagation, I noticed memory leaks due to allocating products at begin run time (function init()) and not always deleting the previous products first. These need to be fixed in 7_4_X
Rather than deciphering the mess and adding deletes where needed, it was much better and safer just to use smart pointers, rather than bare pointers, for the data members owned by this class.
While I was at it, it was much easier and safer also add the consumes interface, so this PR also includes it.
The justifications are:

  1. This class already had the consumes interface partially implemented in 7_4_X.
  2. This keeps the files similar or identical in 7_4_X and 7_5_X.
  3. The fixes for the memory leaks touched many more lines of code than those for the consumes interface.

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 3, 2015

A new Pull Request was created by @wmtan for CMSSW_7_4_X.

fix memory leaks in FastTSGFromPropagation

It involves the following packages:

FastSimulation/Muons

@ssekmen, @nclopezo, @lveldere, @civanch, @mdhildreth, @cmsbuild can you please review it and eventually sign? Thanks.
@Martin-Grunewald, @matt-komm this is something you requested to watch as well.
You can sign-off by replying to this message having '+1' in the first line of your reply.
You can reject by replying to this message having '-1' in the first line of your reply.
If you are a L2 or a release manager you can ask for tests by saying 'please test' in the first line of a comment.
@Degano you are the release manager for this.
You can merge this pull request by typing 'merge' in the first line of your comment.

@lveldere
Copy link
Contributor

lveldere commented Apr 5, 2015

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 5, 2015

The tests are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 5, 2015

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 5, 2015

@lveldere
Copy link
Contributor

lveldere commented Apr 7, 2015

+1

thanks a lot Bill!

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 7, 2015

This pull request is fully signed and it will be integrated in one of the next CMSSW_7_4_X IBs unless changes (tests are also fine). This pull request requires discussion in the ORP meeting before it's merged. @davidlange6, @Degano, @ktf, @smuzaffar

@davidlange6
Copy link
Contributor

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants