Skip site navigation (1) Skip section navigation (2)

atexit vs. on_exit

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: atexit vs. on_exit
Date: 2011-12-22 20:23:37
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Are there any supported platforms that have only on_exit() but not

It would be good in some cases to rewrite custom arrangements such as
exit_nicely() or die_horribly() using those exit hooks, but supporting
both through ifdefs makes the code more ugly than before.  I dug around
the buildfarm logs and documentation around the internet, and it appears
that all non-ancient platforms support atexit().  The use of on_exit()
in PostgreSQL source code appears to come from the original Postgres95

I would like to get rid of on_exit().  Alternatively, atexit() could be
implemented in libpgport as a wrapper around on_exit().


pgsql-hackers by date

Next:From: Robert HaasDate: 2011-12-22 20:24:26
Subject: Re: LibreOffice driver 3: pg_config and linking statically to libpq
Previous:From: Jignesh ShahDate: 2011-12-22 20:23:23
Subject: Re: Page Checksums + Double Writes

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group