summaryrefslogtreecommitdiff
path: root/win32/winutil.c
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2020-05-15 10:44:14 +0300
committerDmitry Stogov <dmitry@zend.com>2020-05-15 10:44:14 +0300
commitba0731cd53b47de1d1dbadb63079da636b579fed (patch)
treef0d95aef37ca5266faaa3d1fab4494f4aeecbbd5 /win32/winutil.c
parente5e25d635273b6d40909e74fa7ff5493a4a12ce9 (diff)
parentc91f3497176479a9de5fa4adea6149c8cdc8f424 (diff)
downloadphp-git-ba0731cd53b47de1d1dbadb63079da636b579fed.tar.gz
Merge branch 'master' of git.php.net:php-src
* 'master' of git.php.net:php-src: fixed typo of bug id (#79599) master doesn't been affected since we are not passing errcontext now Fixed bug #97599 (coredump in set_error_handler) Fix #79557: extension_dir = ./ext now use current directory for base Fix #79596: MySQL FLOAT truncates to int some locales [ci skip] Fix NEWS
Diffstat (limited to 'win32/winutil.c')
-rw-r--r--win32/winutil.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/win32/winutil.c b/win32/winutil.c
index 7da505b1b4..a886964bf0 100644
--- a/win32/winutil.c
+++ b/win32/winutil.c
@@ -438,7 +438,13 @@ PHP_WINUTIL_API char *php_win32_get_username(void)
static zend_always_inline BOOL is_compatible(const char *name, BOOL is_smaller, char *format, char **err)
{/*{{{*/
- PLOADED_IMAGE img = ImageLoad(name, NULL);
+ /* work around ImageLoad() issue */
+ char *name_stripped = name;
+ if (name[0] == '.' && IS_SLASH(name[1])) {
+ name_stripped += 2;
+ }
+
+ PLOADED_IMAGE img = ImageLoad(name_stripped, NULL);
if (!img) {
DWORD _err = GetLastError();