static void check_pipe(int err) { if (err == EPIPE) { if (in_async()) async_exit(141); signal(SIGPIPE, SIG_DFL); raise(SIGPIPE); /* Should never happen, but just in case... */ exit(141); } }
static NORETURN void die_async(const char *err, va_list params) { vreportf("fatal: ", err, params); if (in_async()) { struct async *async = pthread_getspecific(async_key); if (async->proc_in >= 0) close(async->proc_in); if (async->proc_out >= 0) close(async->proc_out); pthread_exit((void *)128); } exit(128); }
static const char *get_trace_prefix(void) { return in_async() ? "sideband" : packet_trace_prefix; }