ROOT version: 6.40.02
entries written: A=501 B=1055 C=806 → true total = 2362
per-chain GetEntries(): a=501 b=1055 c=806 (sum=2362)
after a->Add(b); a->Add(c):
GetEntries() = 489 ← WRONG (expected 2362)
GetEntriesFast() = 489 ← WRONG
files in chain = 16 (all present)
reachable via LoadTree loop = 2362 ← correct total
single chain (Add per file): GetEntries() = 2362 ← correct
It is known to be broken in 6.40.02, 6.38.04 but correct in 6.38.02 and older.
This problem has been reported at https://root-forum.cern.ch/t/tchain-add-tchain-leaves-getentries-reporting-a-wrong-too-small-value/64904
and can be reproduced chain_add_entries.C
with the incorrect output being similar to:
It is known to be broken in 6.40.02, 6.38.04 but correct in 6.38.02 and older.