]> granicus.if.org Git - php/commitdiff
- use cwd_expand now
authorPierre Joye <pajoye@php.net>
Tue, 26 Jul 2011 07:30:41 +0000 (07:30 +0000)
committerPierre Joye <pajoye@php.net>
Tue, 26 Jul 2011 07:30:41 +0000 (07:30 +0000)
ext/spl/spl_directory.c

index 81de56c7ce556848fef8176b5177ad123b36fbbd..21986e171be5d35835810b879f0d840d87f20ee3 100755 (executable)
@@ -1219,10 +1219,7 @@ SPL_METHOD(SplFileInfo, getLinkTarget)
 #if defined(PHP_WIN32) || HAVE_SYMLINK
        if (!IS_ABSOLUTE_PATH(intern->file_name, intern->file_name_len)) {
                char expanded_path[MAXPATHLEN];
-
-               /* TODO: Fix expand_filepath to do not resolve links but only expand the path 
-                  (Pierre) */
-               if (!expand_filepath(intern->file_name, expanded_path TSRMLS_CC)) {
+               if (!expand_filepath_with_mode(intern->file_name, expanded_path, NULL, 0, CWD_EXPAND  TSRMLS_CC)) {
                        php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such file or directory");
                        RETURN_FALSE;
                }