]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - RAW/AliRawReaderRoot.cxx
Adding omega3pi task, swtich on PhysicsSelection for GammaConv, added option -use...
[u/mrichter/AliRoot.git] / RAW / AliRawReaderRoot.cxx
index 6cd69416364f7416310588ec3ea34f3902afe7df..9b840f0e72e43fd5f2dd734cd579ab496b5623eb 100644 (file)
@@ -669,16 +669,22 @@ AliRawReader* AliRawReaderRoot::CloneSingleEvent() const
   // access to the current raw data within
   // several threads (online event display/reco)
 
-  if (GetEvent()) {
+  if (fEvent) {
     // Root formatted raw data
-    AliRawVEvent *gdcRootEvent = (AliRawVEvent*) GetEvent()->Clone();
+    AliRawVEvent *gdcRootEvent = (AliRawVEvent*)fEvent->Clone();
     for (Int_t ldcCounter=0; ldcCounter < gdcRootEvent->GetNSubEvents(); ldcCounter++) {
       AliRawVEvent *ldcRootEvent = gdcRootEvent->GetSubEvent(ldcCounter);
+      AliRawVEvent *subEvent = fEvent->GetSubEvent(ldcCounter);
       for (Int_t eqCounter=0; eqCounter < ldcRootEvent->GetNEquipments(); eqCounter++) {
        AliRawVEquipment *equipment=ldcRootEvent->GetEquipment(eqCounter);
-       equipment->CloneRawData();
+       AliRawVEquipment *eq = subEvent->GetEquipment(eqCounter);
+       equipment->CloneRawData(eq->GetRawData());
       }
     }
+    // Reset original event and newly
+    // produced one
+    gdcRootEvent->GetSubEvent(-1);
+    fEvent->GetSubEvent(-1);
     return new AliRawReaderRoot(gdcRootEvent);
   }
   return NULL;