From: Lennart Poettering Date: Tue, 19 Apr 2011 20:17:54 +0000 (+0200) Subject: manager: when running in test mode, do not write generated unit files to /run/systemd... X-Git-Tag: v25~16 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a08dab55f2691358720144c4570ff78e3bc461b3;p=systemd manager: when running in test mode, do not write generated unit files to /run/systemd/generator --- diff --git a/src/manager.c b/src/manager.c index 495c8e6b..b59339b1 100644 --- a/src/manager.c +++ b/src/manager.c @@ -2937,7 +2937,7 @@ void manager_run_generators(Manager *m) { const char *p; char user_path[] = "/tmp/systemd-generator-XXXXXX"; - if (m->running_as == MANAGER_SYSTEM) { + if (m->running_as == MANAGER_SYSTEM && getpid() == 1) { p = "/run/systemd/generator"; if (mkdir_p(p, 0755) < 0) {