diff options
author | Anatol Belski <ab@php.net> | 2015-04-04 20:28:58 +0200 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2015-04-04 20:28:58 +0200 |
commit | f51a9c71dd011f7d6879b326280adc05ae45f7f7 (patch) | |
tree | 3994a8273ccbaee06594a1daf1e70c19fb0f9d96 | |
parent | 30d59aed1c5a27435149c0609ad8a66802df117d (diff) | |
download | php-git-f51a9c71dd011f7d6879b326280adc05ae45f7f7.tar.gz |
initialize EG(windows_version_info)
there are more places refering to this, but seems it was never
initialized
-rw-r--r-- | Zend/zend.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Zend/zend.c b/Zend/zend.c index 77f7196203..77be1cd5a9 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -516,6 +516,13 @@ static void executor_globals_ctor(zend_executor_globals *executor_globals) /* {{ executor_globals->exception_class = NULL; executor_globals->exception = NULL; executor_globals->objects_store.object_buckets = NULL; +#ifdef ZEND_WIN32 + ZeroMemory(&executor_globals->windows_version_info, sizeof(OSVERSIONINFOEX)); + executor_globals->windows_version_info.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX); + if (!GetVersionEx((OSVERSIONINFO *) &executor_globals->windows_version_info)) { + ZEND_ASSERT(0); /* Should not happen as sizeof is used. */ + } +#endif } /* }}} */ |