diff options
author | Andrew Bartlett <abartlet@samba.org> | 2018-04-10 16:06:12 +1200 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2018-06-04 09:55:29 +0200 |
commit | d14cd61f45564b0a85a1946eb0e39fac02fa227d (patch) | |
tree | c7d9a6df1651a45161bdc50f3d717728c56c4ca2 /lib | |
parent | 8f01d946b49730b40481804b2c60cc0b105c458c (diff) | |
download | samba-d14cd61f45564b0a85a1946eb0e39fac02fa227d.tar.gz |
lib/util: Log PANIC before calling pacic action just like s3
This is like the changes made in s3 by
4fa555980070d78b39711ef21d77628d26055bc2
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13454
(cherry picked from commit 3acc00b6808d5d5ad035d9d43526204db1608c8a)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/util/fault.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/util/fault.c b/lib/util/fault.c index 54d84711742..fef82a3fcf7 100644 --- a/lib/util/fault.c +++ b/lib/util/fault.c @@ -123,6 +123,9 @@ _PUBLIC_ const char *panic_action = NULL; static void smb_panic_default(const char *why) _NORETURN_; static void smb_panic_default(const char *why) { + DBG_ERR("PANIC (pid %llu): %s\n", + (unsigned long long)getpid(), why); + #if defined(HAVE_PRCTL) && defined(PR_SET_PTRACER) /* * Make sure all children can attach a debugger. @@ -148,7 +151,6 @@ static void smb_panic_default(const char *why) WEXITSTATUS(result))); } } - DEBUG(0,("PANIC: %s\n", why)); #ifdef SIGABRT CatchSignal(SIGABRT, SIG_DFL); |