fix protection
authorkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 26 Jun 2012 08:49:13 +0000 (08:49 +0000)
committerkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 26 Jun 2012 08:49:13 +0000 (08:49 +0000)
JETAN/AliAnalysisTaskJetCluster.cxx
JETAN/DEV/AliAnalysisTaskJetCluster.cxx

index 5747354..1326951 100644 (file)
@@ -1156,17 +1156,19 @@ void AliAnalysisTaskJetCluster::UserExec(Option_t */*option*/)
       }
 
       AliAODTrack *aodT = 0;
-      if(partLead&&aodOutJet){
-       //set pT of leading constituent of jet
-       aodOutJet->SetPtLeading(partLead->Pt());
-       aodT = dynamic_cast<AliAODTrack*>(partLead);
-       if(aodT){
-         if(aodT->TestFilterBit(fFilterMaskBestPt)){
-           aodOutJet->SetTrigger(AliAODJet::kHighTrackPtBest);
+      if(partLead){
+       if(aodOutJet){
+         //set pT of leading constituent of jet
+         aodOutJet->SetPtLeading(partLead->Pt());
+         aodT = dynamic_cast<AliAODTrack*>(partLead);
+         if(aodT){
+           if(aodT->TestFilterBit(fFilterMaskBestPt)){
+             aodOutJet->SetTrigger(AliAODJet::kHighTrackPtBest);
+           }
          }
        }
       }
-      
+    
      // correlation
      Float_t tmpPhi =  tmpRec.Phi();
      Float_t tmpEta =  tmpRec.Eta();
index 5747354..1326951 100644 (file)
@@ -1156,17 +1156,19 @@ void AliAnalysisTaskJetCluster::UserExec(Option_t */*option*/)
       }
 
       AliAODTrack *aodT = 0;
-      if(partLead&&aodOutJet){
-       //set pT of leading constituent of jet
-       aodOutJet->SetPtLeading(partLead->Pt());
-       aodT = dynamic_cast<AliAODTrack*>(partLead);
-       if(aodT){
-         if(aodT->TestFilterBit(fFilterMaskBestPt)){
-           aodOutJet->SetTrigger(AliAODJet::kHighTrackPtBest);
+      if(partLead){
+       if(aodOutJet){
+         //set pT of leading constituent of jet
+         aodOutJet->SetPtLeading(partLead->Pt());
+         aodT = dynamic_cast<AliAODTrack*>(partLead);
+         if(aodT){
+           if(aodT->TestFilterBit(fFilterMaskBestPt)){
+             aodOutJet->SetTrigger(AliAODJet::kHighTrackPtBest);
+           }
          }
        }
       }
-      
+    
      // correlation
      Float_t tmpPhi =  tmpRec.Phi();
      Float_t tmpEta =  tmpRec.Eta();