From: Björn Jacke Date: Mon, 5 Jun 2023 16:10:07 +0000 (+0200) Subject: logging: use DBG_STARTUP_NOTICE for startup message X-Git-Tag: talloc-2.4.2~636 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=159cfde446c95c387ef212be103b109ea0dca93d;p=thirdparty%2Fsamba.git logging: use DBG_STARTUP_NOTICE for startup message BUG: https://bugzilla.samba.org/show_bug.cgi?id=15377 Signed-off-by: Bjoern Jacke Reviewed-by: Andrew Bartlett --- diff --git a/source3/rpc_server/rpc_host.c b/source3/rpc_server/rpc_host.c index 337076b5063..c3c4cb97e21 100644 --- a/source3/rpc_server/rpc_host.c +++ b/source3/rpc_server/rpc_host.c @@ -2902,10 +2902,10 @@ int main(int argc, const char *argv[]) reopen_logs(); - DEBUG(0, ("%s version %s started.\n", + DBG_STARTUP_NOTICE("%s version %s started.\n" + COPYRIGHT_STARTUP_MESSAGE "\n", progname, - samba_version_string())); - DEBUGADD(0,("%s\n", COPYRIGHT_STARTUP_MESSAGE)); + samba_version_string()); (void)winbind_off(); ok = init_guest_session_info(frame); diff --git a/source3/rpc_server/rpc_worker.c b/source3/rpc_server/rpc_worker.c index 8ed7444e003..691e0ec57f0 100644 --- a/source3/rpc_server/rpc_worker.c +++ b/source3/rpc_server/rpc_worker.c @@ -1152,10 +1152,10 @@ int rpc_worker_main( reopen_logs(); - DEBUG(0, ("%s version %s started.\n", - progname, - samba_version_string())); - DEBUGADD(0,("%s\n", COPYRIGHT_STARTUP_MESSAGE)); + DBG_STARTUP_NOTICE("%s version %s started.\n" + COPYRIGHT_STARTUP_MESSAGE "\n", + progname, + samba_version_string()); msg_ctx = global_messaging_context(); if (msg_ctx == NULL) { diff --git a/source3/smbd/server.c b/source3/smbd/server.c index 18c79f9df35..ddef5b6de16 100644 --- a/source3/smbd/server.c +++ b/source3/smbd/server.c @@ -1743,8 +1743,9 @@ extern void build_options(bool screen); reopen_logs(); - DEBUG(0,("smbd version %s started.\n", samba_version_string())); - DEBUGADD(0,("%s\n", COPYRIGHT_STARTUP_MESSAGE)); + DBG_STARTUP_NOTICE("smbd version %s started.\n" + COPYRIGHT_STARTUP_MESSAGE "\n", + samba_version_string()); DEBUG(2,("uid=%d gid=%d euid=%d egid=%d\n", (int)getuid(),(int)getgid(),(int)geteuid(),(int)getegid())); diff --git a/source3/winbindd/winbindd.c b/source3/winbindd/winbindd.c index 765e5a2561b..cdd6d4319cb 100644 --- a/source3/winbindd/winbindd.c +++ b/source3/winbindd/winbindd.c @@ -1438,8 +1438,9 @@ int main(int argc, const char **argv) reopen_logs(); - DEBUG(0,("winbindd version %s started.\n", samba_version_string())); - DEBUGADD(0,("%s\n", COPYRIGHT_STARTUP_MESSAGE)); + DBG_STARTUP_NOTICE("winbindd version %s started.\n" + COPYRIGHT_STARTUP_MESSAGE "\n", + samba_version_string()); /* After parsing the configuration file we setup the core path one more time * as the log file might have been set in the configuration and cores's diff --git a/source4/samba/server.c b/source4/samba/server.c index 4698ac0320b..0e61f8ab5cc 100644 --- a/source4/samba/server.c +++ b/source4/samba/server.c @@ -630,11 +630,10 @@ static int binary_smbd_main(TALLOC_CTX *mem_ctx, so set our umask to 0 */ umask(0); - DEBUG(0,("%s version %s started.\n", + DBG_STARTUP_NOTICE("%s version %s started.\n" + COPYRIGHT_STARTUP_MESSAGE "\n", binary_name, - SAMBA_VERSION_STRING)); - DEBUGADD(0,("Copyright Andrew Tridgell and the Samba Team" - " 1992-2023\n")); + SAMBA_VERSION_STRING); if (sizeof(uint16_t) < 2 || sizeof(uint32_t) < 4 ||