X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=EMCAL%2FAliEMCALGeoUtils.cxx;h=a7ed1477c74ad48f3b6a778744fc0e7bce76760c;hb=39ea291a502fa7dde945fcbecd162b215a605b54;hp=e4c9bab0514b7c95859dc5cb43dc49a57e81a106;hpb=ef4799a726d94120b3d93cd58a05d8bed27dce4c;p=u%2Fmrichter%2FAliRoot.git diff --git a/EMCAL/AliEMCALGeoUtils.cxx b/EMCAL/AliEMCALGeoUtils.cxx index e4c9bab0514..a7ed1477c74 100644 --- a/EMCAL/AliEMCALGeoUtils.cxx +++ b/EMCAL/AliEMCALGeoUtils.cxx @@ -382,6 +382,10 @@ Bool_t AliEMCALGeoUtils::SuperModuleNumberFromEtaPhi(Double_t eta, Double_t phi, phi = TVector2::Phi_0_2pi(phi); // move phi to (0,2pi) boundaries for(i=0; i<6; i++) { + + //Check if it is not the complete geometry + if (i >= fEMCGeometry->GetNumberOfSuperModules()/2) return kFALSE; + if(phi>=fPhiBoundariesOfSM[2*i] && phi<=fPhiBoundariesOfSM[2*i+1]) { nSupMod = 2*i; if(eta < 0.0) nSupMod++;