diff options
| author | Thomas Munro | 2022-01-10 10:54:11 +0000 |
|---|---|---|
| committer | Thomas Munro | 2022-01-10 11:04:33 +0000 |
| commit | f3e78069db7f7a753ebfe1010b810e47e0d2aa9a (patch) | |
| tree | 87b4da09ae69dfbcbd47d65c206cfd0a2fe88335 /src/bin | |
| parent | ee419607381dd9a8031f2bc226c742a3289b7f33 (diff) | |
Make EXEC_BACKEND more convenient on Linux and FreeBSD.
Try to disable ASLR when building in EXEC_BACKEND mode, to avoid random
memory mapping failures while testing. For developer use only, no
effect on regular builds.
Suggested-by: Andres Freund <andres@anarazel.de>
Tested-by: Bossart, Nathan <bossartn@amazon.com>
Discussion: https://postgr.es/m/20210806032944.m4tz7j2w47mant26%40alap3.anarazel.de
Diffstat (limited to 'src/bin')
| -rw-r--r-- | src/bin/pg_ctl/pg_ctl.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c index 4986c8f5177..070072299f1 100644 --- a/src/bin/pg_ctl/pg_ctl.c +++ b/src/bin/pg_ctl/pg_ctl.c @@ -451,6 +451,10 @@ start_postmaster(void) fflush(stdout); fflush(stderr); +#ifdef EXEC_BACKEND + pg_disable_aslr(); +#endif + pm_pid = fork(); if (pm_pid < 0) { |
