ID: 22740 Updated by: [EMAIL PROTECTED] Reported By: ben at spamcop dot net -Status: Analyzed +Status: Bogus Bug Type: Feature/Change Request PHP Version: 4.3.1 New Comment:
Yup, I understand that and can see merit in that request, but your proposed implementation is bad. There is no reason to tie this to the realpath() call. Perhaps something like a find_include_path() Previous Comments: ------------------------------------------------------------------------ [2003-03-16 21:31:37] ben at spamcop dot net Ok, I wasn't aware of that. The idea was to have some generic way to find files in the include path for functions that want file system paths as their arguments. ------------------------------------------------------------------------ [2003-03-16 20:45:54] [EMAIL PROTECTED] But why attach this to the realpath() call? Do you realize how amazingly expensive realpath()'ing multiple paths would be? There is a stat syscall for each and every directory in each path plus the final stat for the file itself. So say you had an include_path with 4 paths in it each one being 5 directories deep, that one realpath() call will cost you 25 stat calls. Ouch! ------------------------------------------------------------------------ [2003-03-16 20:35:57] ben at spamcop dot net Many file open functions have an optional parameter that allows for searching the include_path for the given file. If such an optional parameter would be added to realpath(), all functions that do not offer such a parameter could be passed files from the include_path, too. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=22740&edit=1