pg_basebackup: Use atexit()

Instead of using our custom disconnect_and_exit(), just register the
desired cleanup using atexit() and use the standard exit() to leave
the program.

Reviewed-by: Alvaro Herrera <[email protected]>
Reviewed-by: Michael Paquier <[email protected]>
Discussion: 
https://www.postgresql.org/message-id/flat/[email protected]/

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/a4205fa00d526c3158c677a3d82042f88d429f84

Modified Files
--------------
src/bin/pg_basebackup/pg_basebackup.c  | 142 +++++++++++++++++----------------
src/bin/pg_basebackup/pg_receivewal.c  |  45 ++++++-----
src/bin/pg_basebackup/pg_recvlogical.c |  18 ++---
3 files changed, 104 insertions(+), 101 deletions(-)

Reply via email to