]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - CORRFW/AliCFPairPidCut.cxx
Initialize the path name to the geometry file in the Init and not in the InitParameters
[u/mrichter/AliRoot.git] / CORRFW / AliCFPairPidCut.cxx
index 8cfcfa68208ecd3aa96581edff0291443742cd09..a5665928a846012a84f9c848919b87afcd0cc872 100755 (executable)
@@ -74,17 +74,16 @@ Bool_t AliCFPairPidCut::IsSelected(TObject* obj) {
   // loops over decisions of single cuts and returns if the track is accepted
   //
 
-  if (!obj) return kFALSE ;
-  TString className(obj->ClassName());
+  AliCFPair* pair = dynamic_cast<AliCFPair*>(obj);
+  if (!pair) return kFALSE ;
+  TString className(pair->ClassName());
   if (className.CompareTo("AliCFPair") != 0) {
     Error("IsSelected","obj must point to a AliCFPair !");
     return kFALSE ;
   }
 
-  AliCFPair* pair = dynamic_cast<AliCFPair*>(obj);
-
-  AliESDtrack* tneg = pair->GetNeg();
-  AliESDtrack* tpos = pair->GetPos();
+  AliVParticle* tneg = pair->GetNeg();
+  AliVParticle* tpos = pair->GetPos();
 
   if (!tneg || !tpos) return kFALSE ;
   if ( ! fCutNeg->IsSelected(tneg) || ! fCutPos->IsSelected(tpos) ) return kFALSE ;