From d222dc797f065431ba072f0e270de9a0b609349d Mon Sep 17 00:00:00 2001 From: abercuci Date: Wed, 26 Oct 2011 10:03:01 +0000 Subject: [PATCH] protect against missing debug projection on radial direction --- PWG1/TRD/AliTRDresolution.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/PWG1/TRD/AliTRDresolution.cxx b/PWG1/TRD/AliTRDresolution.cxx index f78fcf0a07e..3838a16b1dc 100644 --- a/PWG1/TRD/AliTRDresolution.cxx +++ b/PWG1/TRD/AliTRDresolution.cxx @@ -1465,8 +1465,10 @@ Bool_t AliTRDresolution::MakeProjectionTrackIn(Bool_t mc) if((h2 = hp[iproj].Projection2D(kNstat, kNcontours, 1))) arr->AddAt(h2, arr->GetEntries()); /*!dx all tracks low momenta*/ iproj = 2; - hp[iproj]+=hp[iproj+9];hp[iproj].fH->SetNameTitle(Form("H%sTrkInXl", mc?"MC":""), "TrackIn :: #Deltax{p_{t}[GeV/c]<0.8}"); - if((h2 = hp[iproj].Projection2D(kNstat, kNcontours, 1))) arr->AddAt(h2, arr->GetEntries()); + if(hp[iproj].fH){ + hp[iproj]+=hp[iproj+9];hp[iproj].fH->SetNameTitle(Form("H%sTrkInXl", mc?"MC":""), "TrackIn :: #Deltax{p_{t}[GeV/c]<0.8}"); + if((h2 = hp[iproj].Projection2D(kNstat, kNcontours, 1))) arr->AddAt(h2, arr->GetEntries()); + } /*!dphi negative tracks all momenta*/ iproj =1; hp[iproj]+=hp[npsel+iproj]; hp[iproj]+=hp[npsel*2+iproj]; hp[iproj].fH->SetNameTitle(Form("H%sTrkInPhn", mc?"MC":""), "TrackIn[-]:: #Delta#phi"); -- 2.43.0