]> git.ipfire.org Git - thirdparty/apache/httpd.git/commit
mpm_worker: Fix AH00045 about children processes not terminating timely.
authorYann Ylavic <ylavic@apache.org>
Fri, 12 Apr 2024 11:02:31 +0000 (11:02 +0000)
committerYann Ylavic <ylavic@apache.org>
Fri, 12 Apr 2024 11:02:31 +0000 (11:02 +0000)
commitd010a86e2d1fccb82e41db6097503370b7868249
tree2b8baf7fd178c0d1153042156b371195cb9865c1
parentf9f742e7ba347ba207aaf23c4676e833a5cc8f1f
mpm_worker: Fix AH00045 about children processes not terminating timely.

* server/mpm/worker/worker.c(setup_threads_runtime):
  Create pollset with APR_POLLSET_WAKEABLE to be able to wake up the listener
  when stopping.

* server/mpm/worker/worker.c(wakeup_listener):
  Wake up the listener using the wakeup pipe (apr_pollset_wakeup).

* server/mpm/worker/worker.c(join_workers):
  Like mpm_event, don't depend on `pthread_kill(listener_thread, 0)` to check
  whether the listener has exited (this does not work on some systems), but use
  the "dying" global variable instead which is set by the listener just before
  exiting.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1916926 13f79535-47bb-0310-9956-ffa450edef68
changes-entries/worker_exit.txt [new file with mode: 0644]
server/mpm/worker/worker.c