chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
core: don't fail to run services in --user instances if $HOME is missing
[elogind.git]
/
src
/
core
/
execute.c
diff --git
a/src/core/execute.c
b/src/core/execute.c
index 7b071e8c9e2a41045f93e472817cce50c005cae9..1f6072c6aba368f886ec24b604e90c5f3de6e4d5 100644
(file)
--- a/
src/core/execute.c
+++ b/
src/core/execute.c
@@
-1617,7
+1617,8
@@
static int exec_child(
return -errno;
}
- if (chdir(context->working_directory ? context->working_directory : "/") < 0) {
+ if (chdir(context->working_directory ?: "/") < 0 &&
+ !context->working_directory_missing_ok) {
*exit_status = EXIT_CHDIR;
return -errno;
}