return r;
}
+// This is only to block the signal
+static int pakfire_jail_SIGCHLD(sd_event_source* source,
+ const struct signalfd_siginfo* si, void* data) {
+ return 0;
+}
+
/*
Called when the timer has expired.
*/
goto ERROR;
}
+ // Listen for SIGCHLD
+ r = sd_event_add_signal(ctx.loop, NULL, SIGCHLD|SD_EVENT_SIGNAL_PROCMASK,
+ pakfire_jail_SIGCHLD, NULL);
+ if (r < 0) {
+ CTX_ERROR(jail->ctx, "Could not register handling SIGCHLD: %s\n", strerror(-r));
+ goto ERROR;
+ }
+
// Enable networking in interactive mode
if (ctx.flags & PAKFIRE_JAIL_PTY_FORWARDING)
ctx.flags |= PAKFIRE_JAIL_HAS_NETWORKING;