#include "sd-event.h"
#include "sd-daemon.h"
-#include "mkdir.h"
#include "capability.h"
#include "clock-util.h"
#include "network-util.h"
format_timestamp(date, sizeof(date), min));
if (clock_settime(CLOCK_REALTIME, timespec_store(&ts, min)) < 0)
- log_error("Failed to restore system clock: %m");
+ log_error_errno(errno, "Failed to restore system clock: %m");
}
return 0;
if (r < 0)
goto finish;
+ /* We need one process for ourselves, plus one thread for the asynchronous resolver */
+ if (setrlimit(RLIMIT_NPROC, &RLIMIT_MAKE_CONST(2)) < 0)
+ log_warning_errno(errno, "Failed to lower RLIMIT_NPROC to 2: %m");
+
assert_se(sigprocmask_many(SIG_BLOCK, SIGTERM, SIGINT, -1) == 0);
r = manager_new(&m);