avoid possible leak in case of event with bad vertex, discovered by coverity
authorgconesab <gconesab@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Nov 2010 22:42:47 +0000 (22:42 +0000)
committergconesab <gconesab@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 11 Nov 2010 22:42:47 +0000 (22:42 +0000)
PWG4/PartCorrDep/AliAnaPhoton.cxx

index d865051..2a4366d 100755 (executable)
@@ -409,7 +409,7 @@ void  AliAnaPhoton::MakeAnalysisFillAOD()
     if (GetMixedEvent()) {
       evtIndex=GetMixedEvent()->EventIndexForCaloCluster(calo->GetID()) ; 
       //Get the vertex and check it is not too large in z
-      if(TMath::Abs(GetVertex(evtIndex)[2])> GetZvertexCut()) return ;  
+      if(TMath::Abs(GetVertex(evtIndex)[2])> GetZvertexCut()) continue;
     }
 
     //Cluster selection, not charged, with photon id and in fiducial cut