From: Lennart Poettering Date: Wed, 7 Apr 2010 21:24:41 +0000 (+0200) Subject: main: set $PATH if it isn't set X-Git-Tag: 0.git+20100605+dfd8ee-1~213 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=09082a94b64f0b3b6cec44d4d8f423ab9abd1630;p=platform%2Fupstream%2Fsystemd.git main: set $PATH if it isn't set --- diff --git a/main.c b/main.c index 397e868..ea001b1 100644 --- a/main.c +++ b/main.c @@ -272,6 +272,9 @@ int main(int argc, char *argv[]) { assert_se(action == ACTION_RUN || action == ACTION_TEST); + /* Set up PATH unless it is already set */ + setenv("PATH", "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin", false); + /* Move out of the way, so that we won't block unmounts */ assert_se(chdir("/") == 0);