Fix in operator= (M. Richter)
authorkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 23 Oct 2008 14:54:09 +0000 (14:54 +0000)
committerkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 23 Oct 2008 14:54:09 +0000 (14:54 +0000)
STEER/AliESDEvent.cxx

index eddc4ac..1d6d306 100644 (file)
@@ -245,7 +245,7 @@ AliESDEvent & AliESDEvent::operator=(const AliESDEvent& source) {
       }
       else if(mine->InheritsFrom("TCollection")){
        if(mine->InheritsFrom("TClonesArray"))
-         dynamic_cast<TClonesArray*>(mine)->SetClass(its->ClassName());
+         dynamic_cast<TClonesArray*>(mine)->SetClass(dynamic_cast<TClonesArray*>(its)->GetClass());
        dynamic_cast<TCollection*>(mine)->SetName(name);
       }
       AliDebug(1, Form("adding object %s of type %s", mine->GetName(), mine->ClassName()));