Skip to content

Commit c5bc573

Browse files
David AbdurachmanovDavid Abdurachmanov
David Abdurachmanov
authored and
David Abdurachmanov
committedOct 12, 2015
Fix UB by settting firstStep in AnnealingGhostTrackFitter
Resolved undefined behavior triggered in `AnnealingGhostTrackFitter`: RecoVertex/GhostTrackFitter/interface/AnnealingGhostTrackFitter.h:22:27: runtime error: load of value 105, which is not a valid value for type 'bool' The class has user provided ctor, but `firstStep` is not explicitly initialized thus it's default-initialized to indeterminate value. Signed-off-by: David Abdurachmanov <David.Abdurachmanov@cern.ch>
1 parent 1ef860f commit c5bc573

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎RecoVertex/GhostTrackFitter/src/AnnealingGhostTrackFitter.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
using namespace reco;
1111

12-
AnnealingGhostTrackFitter::AnnealingGhostTrackFitter()
12+
AnnealingGhostTrackFitter::AnnealingGhostTrackFitter() : firstStep(true)
1313
{
1414
annealing.reset(new GeometricAnnealing(3.0, 64.0, 0.25));
1515
}

0 commit comments

Comments
 (0)