Skip to content

Commit

Permalink
Show PID when dying from a signal (JuliaLang#45905)
Browse files Browse the repository at this point in the history
It's often useful to see which PID emitted a particular signal on CI
logs.
  • Loading branch information
staticfloat authored Jul 10, 2022
1 parent ba146fb commit afe3838
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/signal-handling.c
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ void jl_critical_error(int sig, bt_context_t *context, jl_task_t *ct)
sigaddset(&sset, sig);
pthread_sigmask(SIG_UNBLOCK, &sset, NULL);
#endif
jl_safe_printf("\nsignal (%d): %s\n", sig, strsignal(sig));
jl_safe_printf("\n[%d] signal (%d): %s\n", getpid(), sig, strsignal(sig));
}
jl_safe_printf("in expression starting at %s:%d\n", jl_filename, jl_lineno);
if (context && ct) {
Expand Down

0 comments on commit afe3838

Please sign in to comment.