forked from haproxy/haproxy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MEDIUM: errors: get rid of shm_open()
Since 5ee266b ("MINOR: error: simplify startup_logs_init_shm"), the FD of the startup logs is always closed and the HAPROXY_STARTUPLOGS_FD variable is not used anymore. Which means we only need a mmap. Indeed the shm_open() function was only needed to keep the shm between the exec() of the master so we can get the logs stored there after doing the final exec() in wait mode. Since the wait mode doesn't exist anymore and the parsing is done in a worker, we only need to share a memory zone between the master and the worker. This patch removes shm_open() and replace it with a simple mmap(), this way the shared startup-logs become more portable and USE_SHM_OPEN is not required anymore.
- Loading branch information
1 parent
d7fc90a
commit 143be1b
Showing
3 changed files
with
17 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters