1
0
mirror of https://github.com/php/php-src.git synced 2026-04-26 17:38:14 +02:00
This commit is contained in:
Antony Dovgal
2007-06-05 12:02:46 +00:00
parent 7a03838430
commit cf53dfaff3
+4
View File
@@ -829,7 +829,11 @@ SPL_METHOD(SplFileInfo, getLinkTarget)
php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);
#ifdef HAVE_SYMLINK
ret = readlink(intern->file_name, buff, MAXPATHLEN-1);
#else
ret = -1; /* always fail if not implemented */
#endif
if (ret == -1) {
zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Unable to read link %s, error: %s", intern->file_name, strerror(errno));