From: Pierre Joye Date: Tue, 12 Jul 2011 15:15:17 +0000 (+0000) Subject: - Fixed bug #55187, readlink returns weird characters when false result X-Git-Tag: php-5.4.0alpha2~11 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dd1a0be3c090f34ef7f1cd107ad340ae28f1d464;p=php - Fixed bug #55187, readlink returns weird characters when false result --- diff --git a/ext/standard/link_win32.c b/ext/standard/link_win32.c index d7589bbb7b..703bcc1e23 100644 --- a/ext/standard/link_win32.c +++ b/ext/standard/link_win32.c @@ -76,6 +76,7 @@ PHP_FUNCTION(readlink) if (php_sys_readlink(link, target, MAXPATHLEN) == -1) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "readlink failed to read the symbolic link (%s), error %d)", link, GetLastError()); + RETURN_FALSE; } RETURN_STRING(target, 1); }