Fix for bug #75276: Floating point exception at TPC/AliTPCtrackerMI.cxx:6873
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 14 Nov 2010 19:16:12 +0000 (19:16 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 14 Nov 2010 19:16:12 +0000 (19:16 +0000)
TPC/AliTPCtrackerMI.cxx

index 6edb2eb..34624c2 100644 (file)
@@ -6870,6 +6870,11 @@ void  AliTPCtrackerMI::GetShape(AliTPCseed * seed, Int_t row)
   Float_t zdrift = TMath::Abs((fkParam->GetZLength(0)-TMath::Abs(seed->GetZ())));
   Int_t type = (seed->GetSector() < fkParam->GetNSector()/2) ? 0: (row>126) ? 1:2;
   Double_t angulary  = seed->GetSnp();
+
+  if (TMath::Abs(angulary)>AliTPCReconstructor::GetMaxSnpTracker()) {
+    angulary = TMath::Sign(AliTPCReconstructor::GetMaxSnpTracker(),angulary);
+  }
+
   angulary = angulary*angulary/((1.-angulary)*(1.+angulary));
   Double_t angularz  = seed->GetTgl()*seed->GetTgl()*(1.+angulary);