]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Crash protection ::Freq when n of elements ZERO - this should also trigger changes...
authormploskon <mploskon@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 25 Sep 2007 09:43:23 +0000 (09:43 +0000)
committermploskon <mploskon@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 25 Sep 2007 09:43:23 +0000 (09:43 +0000)
HLT/TRD/AliTRDtrackerHLT.cxx

index 33d2e149b2776e08ad0043d902fb66ba01a87ec5..89cf04d296d6ed3ee4b0f4b76d650328a23c8600 100644 (file)
@@ -4342,6 +4342,9 @@ Int_t AliTRDtrackerHLT::Freq(Int_t n, const Int_t *inlist
   // The size of output array has is 2*n 
   //
 
+  if (n <= 0)
+    return 0;
+
   Int_t *sindexS = new Int_t[n];   // Temporary array for sorting
   Int_t *sindexF = new Int_t[2*n];   
   for (Int_t i = 0; i < n; i++) {