From 5521d6985648669a65d0529bb01c7a32edc99294 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Thu, 18 Apr 2013 07:15:03 +0200 Subject: [PATCH] core/execute: only clean the environment, if we have one --- src/core/execute.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/execute.c b/src/core/execute.c index aad11c94a..26cde24f1 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -1772,7 +1772,8 @@ int exec_context_load_environment(const ExecContext *c, char ***l) { return k; } /* Log invalid environment variables with filename */ - p = strv_env_clean_log(p, pglob.gl_pathv[n]); + if (p) + p = strv_env_clean_log(p, pglob.gl_pathv[n]); if (r == NULL) r = p; -- 2.30.2