chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fabe5c0
)
manager: clean environment before passing it on to others
author
Lennart Poettering
<lennart@poettering.net>
Mon, 11 Feb 2013 22:53:14 +0000
(23:53 +0100)
committer
Lennart Poettering
<lennart@poettering.net>
Mon, 11 Feb 2013 22:54:30 +0000
(23:54 +0100)
src/core/manager.c
patch
|
blob
|
history
diff --git
a/src/core/manager.c
b/src/core/manager.c
index c8d7d70dc405e00a8dea0bac251166e6d967a632..4bebb2996fcaaa8c06c280795a7b5334bcd3c261 100644
(file)
--- a/
src/core/manager.c
+++ b/
src/core/manager.c
@@
-71,6
+71,7
@@
#include "path-util.h"
#include "audit-fd.h"
#include "efivars.h"
+#include "env-util.h"
/* As soon as 16 units are in our GC queue, make sure to run a gc sweep */
#define GC_QUEUE_ENTRIES_MAX 16
@@
-289,6
+290,9
@@
static void manager_strip_environment(Manager *m) {
* the initrd interface:
* http://www.freedesktop.org/wiki/Software/systemd/InitrdInterface */
strv_remove_prefix(m->environment, "RD_");
+
+ /* Drop invalid entries */
+ strv_env_clean(m->environment);
}
int manager_new(SystemdRunningAs running_as, Manager **_m) {