postgresql/src
Heikki Linnakangas 58ce9c7850 Don't run atexit callbacks in quickdie signal handlers.
exit() is not async-signal safe. Even if the libc implementation is, 3rd
party libraries might have installed unsafe atexit() callbacks. After
receiving SIGQUIT, we really just want to exit as quickly as possible, so
we don't really want to run the atexit() callbacks anyway.

The original report by Jimmy Yih was a self-deadlock in startup_die().
However, this patch doesn't address that scenario; the signal handling
while waiting for the startup packet is more complicated. But at least this
alleviates similar problems in the SIGQUIT handlers, like that reported
by Asim R P later in the same thread.

Backpatch to 9.3 (all supported versions).

Discussion: https://www.postgresql.org/message-id/CAOMx_OAuRUHiAuCg2YgicZLzPVv5d9_H4KrL_OFsFP%3DVPekigA%40mail.gmail.com
2018-08-08 19:10:07 +03:00
..
backend Don't run atexit callbacks in quickdie signal handlers. 2018-08-08 19:10:07 +03:00
bin Fix pg_upgrade to handle event triggers in extensions correctly. 2018-08-07 15:43:49 -04:00
common Unlink static libraries before rebuilding them. 2015-03-01 13:06:39 -05:00
include Stamp 9.3.24. 2018-08-06 16:13:40 -04:00
interfaces Stamp 9.3.24. 2018-08-06 16:13:40 -04:00
makefiles Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-07-09 17:23:32 -04:00
pl Translation updates 2018-08-06 19:30:02 +02:00
port Stamp 9.3.24. 2018-08-06 16:13:40 -04:00
template AIX: Test the -qlonglong option before use. 2015-07-17 03:02:03 -04:00
test Further fixes for quoted-list GUC values in pg_dump and ruleutils.c. 2018-07-31 13:00:08 -04:00
timezone Update time zone data files to tzdata release 2018e. 2018-05-09 13:56:06 -04:00
tools Clear severity 5 perlcritic warnings from vcregress.pl 2018-05-06 07:40:25 -04:00
tutorial Remove tabs after spaces in C comments 2014-05-06 11:26:28 -04:00
.gitignore Convert cvsignore to gitignore, and add .gitignore for build targets. 2010-09-22 12:57:04 +02:00
bcc32.mak Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00
DEVELOPERS Replace a couple of references to files that no longer exist in the source 2009-05-04 08:08:47 +00:00
Makefile Create libpgcommon, and move pg_malloc et al to it 2013-02-12 11:21:05 -03:00
Makefile.global.in Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-07-09 17:23:32 -04:00
Makefile.shlib Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-07-09 17:23:32 -04:00
nls-global.mk nls-global.mk: search build dir for source files, too 2016-06-07 18:55:18 -04:00
win32.mak Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00