- Fixed bug #55187, readlink returns weird characters when false result

This commit is contained in:
Pierre Joye 2011-07-12 15:15:17 +00:00
parent 96b5e69889
commit b6745ea43a

View File

@ -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);
}