GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Bugs, Fixes, Releases » A bug in FairRootManager
A bug in FairRootManager [message #15785] Tue, 14 January 2014 16:03 Go to next message
Jifeng Hu is currently offline  Jifeng Hu
Messages: 31
Registered: October 2012
continuous participant
From: *wlan.uni-giessen.de
The Data Exchange between tasks is supported by FairRootManager.
In normal, different TClonesArray in many tasks are created and registered in FairRootManager, then also could be retrieved. FairRootManager provides many interfaces to do that.

For example, create and register a TClonesArray in a way
(A)
fEmcDigiArray = new TClonesArray("PndEmcDigi");// PndEmcDigi, Class Name
FairRootManager::Instance()->Register("EmcDigi", "Emc", fEmcDigiArray, kTRUE);
where "PndEmcDigi" is the Class Name, "EmcDigi" is the Branch Name, "Emc" is the Folder Name.

or another way,
(B)
fEmcDigiArray = FairRootManager::Instance()->Register("EmcDigi", "PndEmcDigi", "Emc", kTRUE);

However, when we want to retrieve this branch,
fEmcDigiArrayRef = FairRootManager::Instance()->GetTClonesArray("EmcDigi");

retrieval fails when in way of (A), and succeeds in way of (B).

The reason for that is a bug inside FairRootManager.
When invoking (B), an active container (std::map) was filled, and skipped when invoking (A).

So please either uniform a standard interface or make a new logic.

[Updated on: Tue, 14 January 2014 16:06]

Report message to a moderator

Re: A bug in FairRootManager [message #15786 is a reply to message #15785] Tue, 14 January 2014 17:56 Go to previous message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *to.infn.it
Dear Jifeng,
since this topic is about base classes and not pandaroot, it would be better to post it under fairroot topic here. At least they can check and modify the code, we cannot.
Previous Topic: [FIXED] crash in run/digi_complete.C
Next Topic: [FIXED] crash in run/reco_complete.C
Goto Forum:
  


Current Time: Mon Apr 29 03:32:28 CEST 2024

Total time taken to generate the page: 0.00717 seconds