]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Coverity 17799
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 23 Jan 2012 13:48:52 +0000 (13:48 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 23 Jan 2012 13:48:52 +0000 (13:48 +0000)
STEER/STEERBase/AliTPCdEdxInfo.cxx
STEER/STEERBase/AliTPCdEdxInfo.h

index 59c9aa0311e2a79836f06af5687c30d9f8220a34..28a53c6357ca05b764f207589bee3045833e2ccf 100644 (file)
@@ -48,6 +48,28 @@ AliTPCdEdxInfo::AliTPCdEdxInfo(const AliTPCdEdxInfo& source):
 
 }
 
+AliTPCdEdxInfo& AliTPCdEdxInfo::operator=(const AliTPCdEdxInfo& source)         
+{       
+    //          
+    // assignment operator      
+    //
+
+  if (&source == this) return *this;
+  TObject::operator=(source);
+
+  Double32_t signal[4]; Char_t ncl[3]; Char_t nrows[3];         
+  source.GetTPCSignalRegionInfo(signal, ncl, nrows);    
+  for (Int_t i=0;i<3; i++){     
+    fTPCsignalRegion[i]=signal[i];      
+    fTPCsignalNRegion[i]=ncl[i];        
+    fTPCsignalNRowRegion[i]=nrows[i];   
+  }     
+  fTPCsignalRegion[3]=signal[3];
+
+  return *this;
+
+}
+
 void  AliTPCdEdxInfo::GetTPCSignalRegionInfo(Double32_t signal[4], Char_t ncl[3], Char_t nrows[3]) const {
   //
   // Get the TPC dEdx variables per region
index 21835c7e41c2cd460722a2f59c3a0293399696a7..5c3e123b155b86d2dd452e0a0ddff5c510d6d159 100644 (file)
@@ -8,6 +8,7 @@ class AliTPCdEdxInfo : public TObject
 public:
   AliTPCdEdxInfo();
   AliTPCdEdxInfo(const AliTPCdEdxInfo& source);
+  AliTPCdEdxInfo& operator=(const AliTPCdEdxInfo& source);
   //
   void     GetTPCSignalRegionInfo(Double32_t signal[4], Char_t ncl[3], Char_t nrows[3]) const;
   void     SetTPCSignalRegionInfo(Double32_t signal[4], Char_t ncl[3], Char_t nrows[3]);