]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: startup: rename on_new_child_failure to mworker_on_new_child_failure
authorValentine Krasnobaeva <vkrasnobaeva@haproxy.com>
Fri, 22 Nov 2024 21:41:46 +0000 (22:41 +0100)
committerWilliam Lallemand <wlallemand@haproxy.com>
Mon, 25 Nov 2024 14:20:24 +0000 (15:20 +0100)
This patch prepares the moving of on_new_child_failure definition into
mworker.c. So, let's rename it accordingly and let's also update its
description.

include/haproxy/global.h
src/haproxy.c
src/mworker.c

index eb1fc6ec24625a412f7add193ee9da42cfa5fc97..d3cc12221a52c079ed43724412273b5e06b87b1c 100644 (file)
@@ -68,7 +68,7 @@ void display_version();
 
 void mworker_accept_wrapper(int fd);
 void mworker_reload(int hardreload);
-void on_new_child_failure(void);
+void mworker_on_new_child_failure(void);
 
 /* to be used with warned and WARN_* */
 static inline int already_warned(unsigned int warning)
index a3a36bbb1a75ef64901b1ba3d02d4deaaed8fbdc..4b880b81cd6fb82b77ebccd1b2bfae81e09b35a0 100644 (file)
@@ -915,9 +915,10 @@ static void mworker_loop()
 }
 
 /*
- * Reexec the process in failure mode, instead of exiting
+ * Performs some routines for the worker process, which has failed the reload,
+ * updates the global load_status.
  */
-void on_new_child_failure()
+void mworker_on_new_child_failure()
 {
        struct mworker_proc *child;
 
index be453990a210d286f9ab731fdc682154f988049b..ffd4840574418995e3bf43ad8bfb0a286fb66789 100644 (file)
@@ -356,7 +356,7 @@ restart_wait:
                        /* We didn't find the PID in the list, that shouldn't happen but we can emit a warning */
                        ha_warning("Process %d exited with code %d (%s)\n", exitpid, status, (status >= 128) ? strsignal(status - 128) : "Exit");
                } else if (child->options & PROC_O_INIT) {
-                       on_new_child_failure();
+                       mworker_on_new_child_failure();
 
                        /* Detach all listeners */
                        for (curproxy = proxies_list; curproxy; curproxy = curproxy->next) {