The returned value from G4ProcessManager::GetProcessListLength() happened to be 2x bigger than G4ProcessManager::GetProcessList()->length() for the particle Cr51[0.0] (coming from PiMinusAbsorptionAtRest process). Possible reason for that can be (?) the copy constructor of G4ProcessManager: G4ProcessManager::G4ProcessManager(G4ProcessManager &right) :duringTracking(false) { // .. skipped numberOfProcesses = right.numberOfProcesses; // ...skipped for (G4int idx=0; idx < right.numberOfProcesses; idx++) { // copy contents in theProcessList // ... skipped numberOfProcesses +=1; } // ... }
It is an obvious bug. I fixed it and revised version will be included in the tag "procman-V03-02-01".