fixed missing TDirectory handling of RunSummary in dump_header.cpp
All checks were successful
Build and Deploy Documentation / build-and-deploy (push) Successful in 20s
All checks were successful
Build and Deploy Documentation / build-and-deploy (push) Successful in 20s
This commit is contained in:
@@ -270,9 +270,14 @@ int dump_header_root(const std::string fileName, const bool summary, const bool
|
|||||||
}
|
}
|
||||||
|
|
||||||
// summary as well?
|
// summary as well?
|
||||||
if (summary && (fileType == DH_MUSR_ROOT)) {
|
if (summary && ((fileType == DH_MUSR_ROOT) || (fileType == DH_MUSR_ROOT_DIR))) {
|
||||||
TObjArray *runSum=nullptr;
|
TObjArray *runSum=nullptr;
|
||||||
|
|
||||||
|
if (fileType == DH_MUSR_ROOT) // TFolder
|
||||||
runSum = static_cast<TObjArray*>(folder->FindObject("RunSummary"));
|
runSum = static_cast<TObjArray*>(folder->FindObject("RunSummary"));
|
||||||
|
else // TDirectory
|
||||||
|
f.GetObject("RunHeader/RunSummary", runSum);
|
||||||
|
|
||||||
if (!runSum) { // something is wrong!!
|
if (!runSum) { // something is wrong!!
|
||||||
std::cerr << std::endl << "**ERROR** Couldn't obtain RunSummary " << fileName << std::endl;
|
std::cerr << std::endl << "**ERROR** Couldn't obtain RunSummary " << fileName << std::endl;
|
||||||
f.Close();
|
f.Close();
|
||||||
|
|||||||
Reference in New Issue
Block a user