diff options
Diffstat (limited to 'src/basic')
-rw-r--r-- | src/basic/process-util.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/basic/process-util.c b/src/basic/process-util.c index 48a5c719af..1f4c2e4e43 100644 --- a/src/basic/process-util.c +++ b/src/basic/process-util.c @@ -675,7 +675,7 @@ int getenv_for_pid(pid_t pid, const char *field, char **_value) { } line[i] = 0; - if (memcmp(line, field, l) == 0 && line[l] == '=') { + if (strneq(line, field, l) && line[l] == '=') { value = strdup(line + l + 1); if (!value) return -ENOMEM; |