]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Coverity does not like to count the
authormarian <marian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 14 Dec 2010 14:25:19 +0000 (14:25 +0000)
committermarian <marian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 14 Dec 2010 14:25:19 +0000 (14:25 +0000)
size of pointer to the total memory representation.

OK. Fixed.
(Marian)

TPC/AliDigits.cxx

index 2e16f5a9e479aee30c23dd42f647b623d1c74561..1341d494bbf9ad89da84adc53285436bf81f447c 100644 (file)
@@ -176,9 +176,11 @@ void AliDigits::Allocate(Int_t rows, Int_t columns)
 Int_t AliDigits::GetSize()
 {
   //
-  //return size of object
+  //return size of object as represented in the memory
   //
-  Int_t size = sizeof(this);
+  //  Int_t size = sizeof(this);
+  Int_t size = 0;   // COVERITY consider the previous statment as bug 
+                    // 
   if (fIndex!=0) size+= sizeof(fIndex)+fIndex->GetSize()*sizeof(Int_t);
   if (fElements!=0) size+= sizeof(fElements)+fElements->GetSize()*sizeof(Short_t);
   return size;