Skip to content

Commit

Permalink
Fix crash in pat::MET when no uncertainties are added
Browse files Browse the repository at this point in the history
  • Loading branch information
Sébastien Brochet committed Sep 22, 2015
1 parent 3c7bd4e commit 794364a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions DataFormats/PatCandidates/src/MET.cc
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,10 @@ MET::findMETTotalShift(MET::METCorrectionLevel cor, MET::METUncertainty shift) c


//find uncertainty shift =============================

if (uncertainties_.empty())
return totShift;

if(shift>=MET::METUncertaintySize) throw cms::Exception("Unsupported", "MET uncertainty does not exist");
if(isSmeared && shift<=MET::JetResDown) shift = (MET::METUncertainty)(MET::METUncertaintySize+shift+1);

Expand Down

0 comments on commit 794364a

Please sign in to comment.