diff options
author | Felipe Pena <felipe@php.net> | 2011-11-19 18:50:49 +0000 |
---|---|---|
committer | Felipe Pena <felipe@php.net> | 2011-11-19 18:50:49 +0000 |
commit | 0c5bb1702b174282f7ac382562b24bdaa94f5974 (patch) | |
tree | a5b0601a2b6501b1d47c7940242f498c140c1c12 | |
parent | b3b3eb8c2f079aa4e91d42a7e53aafeeb04f1b83 (diff) | |
download | php-git-0c5bb1702b174282f7ac382562b24bdaa94f5974.tar.gz |
- Fixed bug #60339 (valgrind reports LEAK --with-mm)
patch by: yohgaki at ohgaki dot net
-rw-r--r-- | ext/session/mod_mm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/session/mod_mm.c b/ext/session/mod_mm.c index 704164aa4a..47e3418c86 100644 --- a/ext/session/mod_mm.c +++ b/ext/session/mod_mm.c @@ -278,7 +278,7 @@ PHP_MINIT_FUNCTION(ps_mm) ps_mm_path = emalloc(save_path_len + 1 + (sizeof(PS_MM_FILE) - 1) + mod_name_len + euid_len + 1); memcpy(ps_mm_path, PS(save_path), save_path_len); - if (PS(save_path)[save_path_len - 1] != DEFAULT_SLASH) { + if (save_path_len && PS(save_path)[save_path_len - 1] != DEFAULT_SLASH) { ps_mm_path[save_path_len] = DEFAULT_SLASH; save_path_len++; } |