]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: remove process shortname arg from smbd_reinit_after_fork()
authorRalph Boehme <slow@samba.org>
Sat, 3 Dec 2022 15:59:39 +0000 (16:59 +0100)
committerJeremy Allison <jra@samba.org>
Wed, 14 Dec 2022 01:38:29 +0000 (01:38 +0000)
All callers already do this explicitly by calling process_set_title().

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/include/proto.h
source3/smbd/scavenger.c
source3/smbd/server.c
source3/smbd/server_exit.c
source3/smbd/smb1_process.c

index 3d3cd93d5bc3dc218a172197e59107e416976c09..4f40470e20f5093f26e80ce0f4671520a82a758e 100644 (file)
@@ -305,8 +305,7 @@ NTSTATUS reinit_after_fork(struct messaging_context *msg_ctx,
                           const char *comment);
 NTSTATUS smbd_reinit_after_fork(struct messaging_context *msg_ctx,
                                struct tevent_context *ev_ctx,
-                               bool parent_longlived,
-                               const char *comment);
+                               bool parent_longlived);
 void *malloc_(size_t size);
 void *Realloc(void *p, size_t size, bool free_old_on_error);
 void add_to_large_array(TALLOC_CTX *mem_ctx, size_t element_size,
index 0d42ae635c2fdda0189e8514d5678b46bf092180..897ddf1617c8b2c4834ae95ad50884354c214cd7 100644 (file)
@@ -246,7 +246,7 @@ static bool smbd_scavenger_start(struct smbd_scavenger_state *state)
                close(fds[0]);
 
                status = smbd_reinit_after_fork(state->msg, state->ev,
-                                               true, "smbd-scavenger");
+                                               true);
                if (!NT_STATUS_IS_OK(status)) {
                        DEBUG(2, ("reinit_after_fork failed: %s\n",
                                  nt_errstr(status)));
index 811cdbc3ccd9dc1aa9129b05b03cbc7144ee5619..d442e7833810bae479203d2c5e26af894d3d4e2c 100644 (file)
@@ -428,7 +428,7 @@ static bool smbd_notifyd_init(struct messaging_context *msg, bool interactive,
                return true;
        }
 
-       status = smbd_reinit_after_fork(msg, ev, true, "smbd-notifyd");
+       status = smbd_reinit_after_fork(msg, ev, true);
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(1, ("%s: reinit_after_fork failed: %s\n",
                          __func__, nt_errstr(status)));
@@ -644,7 +644,7 @@ static bool cleanupd_init(struct messaging_context *msg, bool interactive,
 
        close(up_pipe[0]);
 
-       status = smbd_reinit_after_fork(msg, ev, true, "cleanupd");
+       status = smbd_reinit_after_fork(msg, ev, true);
        if (!NT_STATUS_IS_OK(status)) {
                DBG_WARNING("reinit_after_fork failed: %s\n",
                            nt_errstr(status));
@@ -1014,7 +1014,7 @@ static void smbd_accept_connection(struct tevent_context *ev,
                 * them, counting worker smbds. */
                CatchChild();
 
-               status = smbd_reinit_after_fork(msg_ctx, ev, true, NULL);
+               status = smbd_reinit_after_fork(msg_ctx, ev, true);
                if (!NT_STATUS_IS_OK(status)) {
                        if (NT_STATUS_EQUAL(status,
                                            NT_STATUS_TOO_MANY_OPENED_FILES)) {
index b4a84e1a3f3ef83014c561a498abf79e4bbf55bf..d216fd7e06dce0f367d6cbbc8182901a12af0e08 100644 (file)
@@ -252,11 +252,11 @@ void smbd_exit_server_cleanly(const char *const explanation)
  */
 NTSTATUS smbd_reinit_after_fork(struct messaging_context *msg_ctx,
                                struct tevent_context *ev_ctx,
-                               bool parent_longlived, const char *comment)
+                               bool parent_longlived)
 {
        NTSTATUS ret;
        am_parent = NULL;
-       ret = reinit_after_fork(msg_ctx, ev_ctx, parent_longlived, comment);
+       ret = reinit_after_fork(msg_ctx, ev_ctx, parent_longlived, NULL);
        initialize_password_db(true, ev_ctx);
        return ret;
 }
index c1e0fc2979f4c9ababc5a6a0f710ac08d4e33777..9edfa2116e957732bd7b371e2aa94e4661a27056 100644 (file)
@@ -2606,8 +2606,7 @@ bool fork_echo_handler(struct smbXsrv_connection *xconn)
 
                status = smbd_reinit_after_fork(xconn->client->msg_ctx,
                                                xconn->client->raw_ev_ctx,
-                                               true,
-                                               "smbd-echo");
+                                               true);
                if (!NT_STATUS_IS_OK(status)) {
                        DEBUG(1, ("reinit_after_fork failed: %s\n",
                                  nt_errstr(status)));