X-Git-Url: http://git.uio.no/git/?p=u%2Fmrichter%2FAliRoot.git;a=blobdiff_plain;f=TPC%2FAliTPCSensorTemp.cxx;h=167daca2f70b142417c1d7b5b78314087ef01717;hp=7f52bf0d44ad12c49609dfe85e8bcc8b418efa1c;hb=0938d4f8b4a727f9a668e68ad21b3f2f574baf54;hpb=70e003f329b33b389595314a66a7d440a079918b diff --git a/TPC/AliTPCSensorTemp.cxx b/TPC/AliTPCSensorTemp.cxx index 7f52bf0d44a..167daca2f70 100644 --- a/TPC/AliTPCSensorTemp.cxx +++ b/TPC/AliTPCSensorTemp.cxx @@ -185,7 +185,7 @@ TClonesArray * AliTPCSensorTemp::ReadTree(TTree *tree, Int_t sector=0; char type[100]; char side[100]; - Int_t num=0; + UInt_t num=0; Int_t echa=0; //Double_t x=0; //Double_t y=0; @@ -329,13 +329,14 @@ TClonesArray * AliTPCSensorTemp::ReadTree(TTree *tree, temp->SetZ(-240); } - if(temp->GetType()==5 && temp->GetSide()==0) { + if ( num < (sizeof(kTSz)/sizeof(kTSz[0]))) { + if(temp->GetType()==5 && temp->GetSide()==0) { temp->SetZ(kTSz[num]); } - if(temp->GetType()==5 && temp->GetSide()==1) { + if(temp->GetType()==5 && temp->GetSide()==1) { temp->SetZ(-kTSz[num]); } - + } } return array;