From: Stanislav Malyshev Date: Tue, 13 Oct 2009 20:10:07 +0000 (+0000) Subject: add safeguard for UpdateIniFromRegistry on NULL arg X-Git-Tag: php-5.3.2RC1~362 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dd15b8810cc54d0a7c5a8c22a8ddcac1c2552a52;p=php add safeguard for UpdateIniFromRegistry on NULL arg --- diff --git a/win32/registry.c b/win32/registry.c index d5f84af595..77089ba6a7 100644 --- a/win32/registry.c +++ b/win32/registry.c @@ -168,6 +168,10 @@ void UpdateIniFromRegistry(char *path TSRMLS_DC) int path_len; HashTable **pht; + if(!path) { + return; + } + if (!PW32G(registry_directories)) { PW32G(registry_directories) = (HashTable*)malloc(sizeof(HashTable)); zend_hash_init(PW32G(registry_directories), 0, NULL, delete_internal_hashtable, 1);