]> granicus.if.org Git - postgresql/commit
Refactor fork()-related code. We need to do various housekeeping tasks
authorNeil Conway <neilc@samurai.com>
Thu, 10 Mar 2005 07:14:03 +0000 (07:14 +0000)
committerNeil Conway <neilc@samurai.com>
Thu, 10 Mar 2005 07:14:03 +0000 (07:14 +0000)
commit164adc4d3924d5f0310dba24d4035313ca69245d
tree4a7dfc4714ac642f31b1a60d31ecdc4ba1d59065
parente829f822239186df59829afae5cc2769b783630b
Refactor fork()-related code. We need to do various housekeeping tasks
before we can invoke fork() -- flush stdio buffers, save and restore the
profiling timer on Linux with LINUX_PROFILE, and handle BeOS stuff. This
patch moves that code into a single function, fork_process(), instead of
duplicating it at the various callsites of fork().

This patch doesn't address the EXEC_BACKEND case; there is room for
further cleanup there.
src/backend/port/beos/support.c
src/backend/postmaster/Makefile
src/backend/postmaster/fork_process.c [new file with mode: 0644]
src/backend/postmaster/pgarch.c
src/backend/postmaster/postmaster.c
src/backend/postmaster/syslogger.c
src/include/postmaster/fork_process.h [new file with mode: 0644]