]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Fix copy ctor in case there is no stored pads (Laurent)
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 17 Jun 2007 20:42:56 +0000 (20:42 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 17 Jun 2007 20:42:56 +0000 (20:42 +0000)
MUON/AliMUONCluster.cxx

index c44a65465a2e922b6b789de1302ec159f1a2014e..b8ead010399961982e002135f6eb8306df906e9a 100644 (file)
@@ -203,7 +203,11 @@ AliMUONCluster::Copy(TObject& obj) const
   ///
   TObject::Copy(obj);
   AliMUONCluster& dest = static_cast<AliMUONCluster&>(obj);
-  dest.fPads = static_cast<TObjArray*>(fPads->Clone());
+  dest.fPads = 0x0;
+  if ( fPads )
+  {
+    dest.fPads = static_cast<TObjArray*>(fPads->Clone());
+  }
   dest.fHasPosition = fHasPosition;
   dest.fPosition = fPosition;
   dest.fPositionError = fPositionError;