return;
}
- /*
- * Ignore SIGPIPE because it should not stop the consumer whenever a
- * SIGPIPE is caught through a FD operation.
- */
- if (sig == SIGPIPE) {
- return;
- }
-
if (ctx) {
lttng_consumer_should_exit(ctx);
}
return ret;
}
- sa.sa_handler = sighandler;
sa.sa_mask = sigset;
sa.sa_flags = 0;
+
+ sa.sa_handler = sighandler;
if ((ret = sigaction(SIGTERM, &sa, NULL)) < 0) {
PERROR("sigaction");
return ret;
return ret;
}
+ sa.sa_handler = SIG_IGN;
if ((ret = sigaction(SIGPIPE, &sa, NULL)) < 0) {
PERROR("sigaction");
return ret;