Import Geant4 11.0.2 source tree
This commit is contained in:
@@ -138,14 +138,18 @@ G4bool G4ExceptionHandler::Notify(const char* originOfException,
|
||||
// --------------------------------------------------------------------
|
||||
void G4ExceptionHandler::DumpTrackInfo()
|
||||
{
|
||||
G4ApplicationState aps = G4StateManager::GetStateManager()->GetCurrentState();
|
||||
G4SteppingManager* steppingMgr = G4RunManagerKernel::GetRunManagerKernel()
|
||||
->GetTrackingManager()
|
||||
->GetSteppingManager();
|
||||
const G4Track* theTrack = steppingMgr->GetfTrack();
|
||||
const G4Step* theStep = steppingMgr->GetfStep();
|
||||
const G4Track *theTrack = nullptr;
|
||||
const G4Step *theStep = nullptr;
|
||||
if (G4StateManager::GetStateManager()->GetCurrentState() == G4State_EventProc)
|
||||
{
|
||||
G4SteppingManager *steppingMgr = G4RunManagerKernel::GetRunManagerKernel()
|
||||
->GetTrackingManager()
|
||||
->GetSteppingManager();
|
||||
theTrack = steppingMgr->GetfTrack();
|
||||
theStep = steppingMgr->GetfStep();
|
||||
}
|
||||
|
||||
if(aps != G4State_EventProc || theTrack == nullptr)
|
||||
if (theTrack == nullptr)
|
||||
{
|
||||
G4cerr << " **** Track information is not available at this moment"
|
||||
<< G4endl;
|
||||
@@ -174,7 +178,7 @@ void G4ExceptionHandler::DumpTrackInfo()
|
||||
<< G4endl;
|
||||
}
|
||||
|
||||
if(aps != G4State_EventProc || !theStep)
|
||||
if (theStep == nullptr)
|
||||
{
|
||||
G4cerr << " **** Step information is not available at this moment"
|
||||
<< G4endl;
|
||||
|
||||
@@ -122,7 +122,11 @@ G4RunManagerKernel::G4RunManagerKernel()
|
||||
G4AllocatorList* allocList = G4AllocatorList::GetAllocatorListIfExist();
|
||||
if(allocList != nullptr)
|
||||
numberOfStaticAllocators = allocList->Size();
|
||||
defaultExceptionHandler = new G4ExceptionHandler();
|
||||
|
||||
if(G4StateManager::GetStateManager()->GetExceptionHandler() == nullptr)
|
||||
{
|
||||
defaultExceptionHandler = new G4ExceptionHandler();
|
||||
}
|
||||
if(fRunManagerKernel != nullptr)
|
||||
{
|
||||
G4Exception("G4RunManagerKernel::G4RunManagerKernel()", "Run0001",
|
||||
@@ -222,7 +226,11 @@ G4RunManagerKernel::G4RunManagerKernel(RMKType rmkType)
|
||||
}
|
||||
#endif
|
||||
|
||||
defaultExceptionHandler = new G4ExceptionHandler();
|
||||
if(G4StateManager::GetStateManager()->GetExceptionHandler() == nullptr)
|
||||
{
|
||||
defaultExceptionHandler = new G4ExceptionHandler();
|
||||
}
|
||||
|
||||
if(fRunManagerKernel != nullptr)
|
||||
{
|
||||
G4Exception("G4RunManagerKernel::G4RunManagerKernel()", "Run0001",
|
||||
|
||||
Reference in New Issue
Block a user