covertity fix 24879
authorfbock <Friederike.Bock@cern.ch>
Mon, 12 Jan 2015 16:01:21 +0000 (17:01 +0100)
committerfbock <Friederike.Bock@cern.ch>
Mon, 12 Jan 2015 16:01:21 +0000 (17:01 +0100)
PWGGA/GammaConv/AliAnalysisTaskGammaConvFlow.cxx

index 0e3178f..7c58715 100644 (file)
@@ -788,13 +788,11 @@ void AliAnalysisTaskGammaConvFlow::Terminate(const Option_t *)
 void AliAnalysisTaskGammaConvFlow::ProcessPhotonCandidatesforV2()
 {
 
-       // Loop over Photon Candidates allocated by ReaderV1
-       
-       
+       // Loop over Photon Candidates allocated by ReaderV1    
        for(Int_t i = 0; i < fGammaCandidates->GetEntries(); i++){
                
                AliAODConversionPhoton *gammaForv2=dynamic_cast<AliAODConversionPhoton*>(fGammaCandidates->At(i));
-
+               if (gammaForv2 == NULL) return;
                AliFlowTrack *sTrack = new AliFlowTrack();
                sTrack->SetForRPSelection(kFALSE);
                sTrack->SetForPOISelection(kTRUE);