KiCad PCB EDA Suite
Loading...
Searching...
No Matches
access_fast_exit.cpp File Reference
#include <database/access_fast_exit.h>
#include <atomic>
#include <cstdio>
#include <kiplatform/app.h>
#include <trace_helpers.h>
#include <wx/log.h>

Go to the source code of this file.

Functions

void MarkAccessWorkerAbandoned ()
 Records that a worker inside the Access engine was abandoned.
 
void ExitFastIfAccessWorkerAbandoned (int aExitCode)
 Ends the process without the normal teardown when an Access engine worker was abandoned, since the Office libraries it is still inside crash when they unload at exit.
 

Function Documentation

◆ ExitFastIfAccessWorkerAbandoned()

void ExitFastIfAccessWorkerAbandoned ( int aExitCode)

Ends the process without the normal teardown when an Access engine worker was abandoned, since the Office libraries it is still inside crash when they unload at exit.

Call it after the application's own shutdown and only from the main thread. Returns at once if no worker was abandoned.

The abandoned session's lock file entry stays behind, and ending the process can wait on redirector I/O.

Parameters
aExitCodeis the code the process would have exited with

Definition at line 50 of file access_fast_exit.cpp.

References KIPLATFORM::APP::TerminateWithCode(), and traceDatabase.

Referenced by PGM_BASE::ExitIfTeardownUnsafe().

◆ MarkAccessWorkerAbandoned()

void MarkAccessWorkerAbandoned ( )

Records that a worker inside the Access engine was abandoned.

The flag is process wide and never cleared.

Definition at line 43 of file access_fast_exit.cpp.

References traceDatabase.

Referenced by ACE_BACKEND::ACE_BACKEND(), and ODBC_BACKEND::~ODBC_BACKEND().