From ba16aade337b16028d1e9e156d83417097c13817 Mon Sep 17 00:00:00 2001 From: Michael Paquier Date: Thu, 27 Sep 2018 07:47:20 +0900 Subject: Switch flags tracking pending interrupts to sig_atomic_t Those previously used bool, which should be safe on any modern platforms, however the C standard is clear that it is better to use sig_atomic_t for variables manipulated in signal handlers. This commit adds at the same time PGDLLIMPORT to ClientConnectionLost. Author: Michael Paquier Reviewed-by: Tom Lane, Chris Travers, Andres Freund Discussion: https://postgr.es/m/20180925011311.GD1354@paquier.xyz --- src/backend/utils/init/globals.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/backend/utils/init/globals.c') diff --git a/src/backend/utils/init/globals.c b/src/backend/utils/init/globals.c index f7d6617a138..5971310aabb 100644 --- a/src/backend/utils/init/globals.c +++ b/src/backend/utils/init/globals.c @@ -27,11 +27,11 @@ ProtocolVersion FrontendProtocol; -volatile bool InterruptPending = false; -volatile bool QueryCancelPending = false; -volatile bool ProcDiePending = false; -volatile bool ClientConnectionLost = false; -volatile bool IdleInTransactionSessionTimeoutPending = false; +volatile sig_atomic_t InterruptPending = false; +volatile sig_atomic_t QueryCancelPending = false; +volatile sig_atomic_t ProcDiePending = false; +volatile sig_atomic_t ClientConnectionLost = false; +volatile sig_atomic_t IdleInTransactionSessionTimeoutPending = false; volatile sig_atomic_t ConfigReloadPending = false; volatile uint32 InterruptHoldoffCount = 0; volatile uint32 QueryCancelHoldoffCount = 0; -- cgit v1.2.3