ID:               20895
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
 Status:           Verified
 Bug Type:         Filesystem function related
 Operating System: Win 2000Pro SP3
 PHP Version:      4.3.0RC2
 New Comment:

Suppose you have a file c:/file.txt and you want to open another file
from the same directory.
If dirname("c:/file.txt"); return '.', then fopen
("./another_file.txt") will fail because it is looking in the wrong
directory, the current current directory. If it returns c:/ or c: then
c: + / + file will resolve to the actual file and open it correctly.


Previous Comments:
------------------------------------------------------------------------

[2002-12-10 20:05:55] [EMAIL PROTECTED]

A couple people just tested this and get the same results as the bug
report with 4.3.0RC2, please explain why this behavior changed.

------------------------------------------------------------------------

[2002-12-08 23:56:53] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php



------------------------------------------------------------------------

[2002-12-08 23:35:37] [EMAIL PROTECTED]

Hello.

Up to 4.2.3:


dirname("c:/");
// or
dirname("c:");
// both returned   '.'


in 4.3.0 RC2, we got now:


dirname("c:/");
// gives you   c:\
dirname("c:");
// gives you   c:


(i) I'm not sure that such path shall be used with dirname(). But after
all, why not? And in fact I used it.
(ii) What's the reason for that behaviour change?
(iii) As some of my classes are now broken, will this new behaviour
become the rule for the future?

Apache independent.
Standarts php.ini (recommended) and httpd.conf
Mozilla 1.2

Thanks.

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=20895&edit=1

Reply via email to