1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-19 13:42:17 +03:00

Teach on_exit_reset() to discard pending cleanups for dsm.

If a postmaster child invokes fork() and then calls on_exit_reset, that
should be sufficient to let it exit() without breaking anything, but
dynamic shared memory broke that by not updating on_exit_reset() to
discard callbacks registered with dynamic shared memory segments.

Per investigation of a complaint from Tom Lane.
This commit is contained in:
Robert Haas
2014-03-10 10:17:19 -04:00
parent 77049443a1
commit cb9a0c7987
3 changed files with 33 additions and 0 deletions

View File

@@ -400,4 +400,5 @@ on_exit_reset(void)
before_shmem_exit_index = 0;
on_shmem_exit_index = 0;
on_proc_exit_index = 0;
reset_on_dsm_detach();
}