Message: "Restarting" Geant4 in the same executable Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None "Restarting" Geant4 in the same executable 

Forum: Run Management
Date: 11 Jun, 2018
From: Sergio Losilla <Sergio Losilla>


I want to write some unit tests using Catch2 ( For these tests, G4RunManager must be instantiated. Unfortunately, the tests crash unless there is only one G4RunManager instance in the whole test suite. The segmentation fault occurs in G4AllocatorPool::Grow().

A simplified example that always crashes would be the following piece of code:

#include "G4MTRunManager.hh"
int main()
        G4RunManager foo;
        G4RunManager bar;
    return 0;

Is there any additional cleanup that can be done after foo falls out of scope, such that this code does not crash?

Thanks beforehand!


 Add Message Add Message
to: ""Restarting" Geant4 in the same executable"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews

[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]