|
[Rivet] Minor problems in Rivet 1.5.0Leif Lönnblad leif.lonnblad at thep.lu.seFri Mar 18 14:40:31 GMT 2011
On 2011-03-18 11:50, Frank Siegert wrote: >> * If I add an analysis which gets removed because of the wrong beam >> energies I get a seg-fault after the message >> >> Analysis 'CMS_2011_S8957746' is incompatible with the provided beams: >> removing > Yep, that seems to be a nasty memory corruption problem that Andy has > tried to track down several times and hasn't managed yet (and nobody > else dares touching the pointer/projection/... system ;-)). It's on the > agenda for 2.0 I believe, and is somewhat related to/tracked in this > ticket: OK, so I traced the problem to a strange line in AnalysisHandler::removeAnalysis: toremove.reset( a.get() ); According to the boost docs, this means that toremove afterwards thinks it is the sole owner of the analysis. But the pointer in the _analysis container also thinks it is the sole owner, and when the analysis is removed from the container it is deleted. And when the function exits, and toremove is destroyed it will try to delete the analysis again, thinking it is the only owner. Changing the line to toremove = a; solves everything. Shall I check it in? Cheers, Leif
More information about the Rivet mailing list |