Fixed a bug on retrieving TPC inner param
authorpulvir <pulvir@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Jan 2010 15:37:02 +0000 (15:37 +0000)
committerpulvir <pulvir@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 11 Jan 2010 15:37:02 +0000 (15:37 +0000)
PWG2/RESONANCES/AliRsnCutBetheBloch.cxx

index 256a9f1..4ea75ef 100644 (file)
@@ -74,7 +74,8 @@ Double_t AliRsnCutBetheBloch::BetheBloch(AliRsnDaughter * const trackRef)
   AliPID pid;
   Double_t mass = pid.ParticleMass(fType);
 
-  // get the track momentum at the inner wall of TPC
+  // get the track momentum at the inner wall of TPC: if absent cut is not passed
+  if (!trackRef->GetRefESD()->GetInnerParam()) return 1000000.0;
   AliExternalTrackParam track(*trackRef->GetRefESD()->GetInnerParam());
 
   Double_t betaGamma = track.P() / mass;