From: Valentine Krasnobaeva Date: Fri, 22 Nov 2024 21:58:53 +0000 (+0100) Subject: MINOR: startup: prefix prepare_master and run_master with mworker_* X-Git-Tag: v3.1.0~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=41cc1fe3103e233d5345d7527a1fc5ca34e0ca0f;p=thirdparty%2Fhaproxy.git MINOR: startup: prefix prepare_master and run_master with mworker_* This patch prepares the move of prepare_master() and run_master() definitions into mworker.c. So, let's at first prefix its names with mworker_*. --- diff --git a/src/haproxy.c b/src/haproxy.c index 25881ce90a..a2dda006e3 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@ -1965,7 +1965,7 @@ static void generate_random_cluster_secret() * CLI at worker side (worker can send its status to master).It only returns if * everything is OK. If something fails, it exits. */ -static void prepare_master() +static void mworker_prepare_master() { struct mworker_proc *tmproc; @@ -2004,7 +2004,7 @@ static void prepare_master() LIST_APPEND(&proc_list, &tmproc->list); } -static void run_master() +static void mworker_run_master() { struct mworker_proc *child, *it; @@ -3058,7 +3058,7 @@ static void run_master_in_recovery_mode(int argc, char **argv) step_init_4(); /* enter in master polling loop */ - run_master(); + mworker_run_master(); } /* parse conf in disovery mode and set modes from config */ @@ -3758,7 +3758,7 @@ int main(int argc, char **argv) * setenv("HAPROXY_MWORKER", "1", 1). */ if (global.mode & MODE_MWORKER) - prepare_master(); + mworker_prepare_master(); /* If we are in a daemon mode and we might be also in master-worker mode: * we should do daemonization fork here to put the main process (which @@ -3890,7 +3890,7 @@ int main(int argc, char **argv) /* Master enters in its polling loop */ if (master) { - run_master(); + mworker_run_master(); /* never get there in master context */ }