projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
62678de
)
strv: don't access potentially NULL string arrays
author
Lennart Poettering
<lennart@poettering.net>
Wed, 2 Oct 2013 17:38:28 +0000
(19:38 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Wed, 2 Oct 2013 17:45:12 +0000
(19:45 +0200)
src/shared/env-util.c
patch
|
blob
|
history
diff --git
a/src/shared/env-util.c
b/src/shared/env-util.c
index
5e29629
..
7976881
100644
(file)
--- a/
src/shared/env-util.c
+++ b/
src/shared/env-util.c
@@
-405,7
+405,9
@@
char **strv_env_clean_log(char **e, const char *message) {
e[k++] = *p;
}
- e[k] = NULL;
+ if (e)
+ e[k] = NULL;
+
return e;
}