Browse Source

daemon: print version in crash backtrace.

Sometimes people only send us the crash, not the logs.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ppa-0.6.1
Rusty Russell 7 years ago
committed by Christian Decker
parent
commit
02b55e35b8
  1. 4
      common/daemon.c

4
common/daemon.c

@ -32,12 +32,12 @@ static int backtrace_status(void *unused UNUSED, uintptr_t pc,
static void crashdump(int sig) static void crashdump(int sig)
{ {
/* We do stderr first, since it's most reliable. */ /* We do stderr first, since it's most reliable. */
warnx("Fatal signal %d", sig); warnx("Fatal signal %d (version %s)", sig, version());
if (backtrace_state) if (backtrace_state)
backtrace_print(backtrace_state, 0, stderr); backtrace_print(backtrace_state, 0, stderr);
/* Now send to parent. */ /* Now send to parent. */
bt_print("FATAL SIGNAL %d", sig); bt_print("FATAL SIGNAL %d (version %s)", sig, version());
if (backtrace_state) if (backtrace_state)
backtrace_full(backtrace_state, 0, backtrace_status, NULL, NULL); backtrace_full(backtrace_state, 0, backtrace_status, NULL, NULL);

Loading…
Cancel
Save