mirror of
https://github.com/postgres/postgres.git
synced 2025-10-25 13:17:41 +03:00
Restructure backend SIGINT/SIGTERM handling so that 'die' interrupts
are treated more like 'cancel' interrupts: the signal handler sets a flag that is examined at well-defined spots, rather than trying to cope with an interrupt that might happen anywhere. See pghackers discussion of 1/12/01.
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.49 2001/01/07 04:17:29 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.50 2001/01/14 05:08:16 tgl Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Globals used all over the place should be declared here and not
|
||||
@@ -34,7 +34,12 @@ ProtocolVersion FrontendProtocol = PG_PROTOCOL_LATEST;
|
||||
|
||||
bool Noversion = false;
|
||||
bool Quiet = false;
|
||||
volatile bool QueryCancel = false;
|
||||
|
||||
volatile bool InterruptPending = false;
|
||||
volatile bool QueryCancelPending = false;
|
||||
volatile bool ProcDiePending = false;
|
||||
volatile bool ImmediateInterruptOK = false;
|
||||
volatile uint32 CritSectionCount = 0;
|
||||
|
||||
int MyProcPid;
|
||||
struct Port *MyProcPort;
|
||||
@@ -56,9 +61,7 @@ BackendId MyBackendId;
|
||||
char *DatabaseName = NULL;
|
||||
char *DatabasePath = NULL;
|
||||
|
||||
bool MyDatabaseIdIsInitialized = false;
|
||||
Oid MyDatabaseId = InvalidOid;
|
||||
bool TransactionInitWasProcessed = false;
|
||||
|
||||
bool IsUnderPostmaster = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user