diff options
-rw-r--r-- | ChangeLog.txt | 1 | ||||
-rw-r--r-- | pseudo_util.c | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt index d61a4ed..4d7a003 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,5 +1,6 @@ 2014-06-13: * (seebs) don't follow symlinks for lutimes. + * (seebs) Use sizeof instead of strlen to initialize static value. 2014-05-27: * (seebs) start noticing umask, mask it out from open or mkdir diff --git a/pseudo_util.c b/pseudo_util.c index 325cabf..e4e1fc8 100644 --- a/pseudo_util.c +++ b/pseudo_util.c @@ -98,7 +98,7 @@ dump_env(char **envp) { int pseudo_has_unload(char * const *envp) { static const char unload[] = "PSEUDO_UNLOAD"; - static size_t unload_len = strlen(unload); + static size_t unload_len = sizeof(unload) - 1; size_t i = 0; /* Is it in the caller environment? */ |