cms-analysis / CombineHarvester

CMSSW package for the creation, editing and analysis of combine datacards and workspaces
cms-analysis.github.io/CombineHarvester/
15 stars 180 forks source link

Fix seg fault for workspaces with RooDataHist objects #328

Closed anigamova closed 1 month ago

anigamova commented 2 months ago

With the new ROOT version (>6.26) the workspaces with RooHistPdf objects give segfault in ch::CombineHarvester::WriteDatacard method. @kcormi noticed that the links with RooDataHist object are lost as soon as ws_store previously defined in CombineTools/src/CombineHarvester_Datacards.cc goes out of scope. I still don't understand what exactly changed in RooDataHist memory management, but the change proposed here fixes the issue.