ID: 29257
Comment by: chernyshevsky at hotmail dot com
Reported By: zet at male dot ru
Status: No Feedback
Bug Type: *Directory/Filesystem functions
Operating System: Windows XP SP1
PHP Version: 4.3.7
New Comment:
How come no one is looking into this? It's reproducible on Linux as
well.
copy("test.txt", "test.txt") -> 0 bytes
You can't avoid this problem just by checking the filename, since one
could be a symlink pointing to the other. It would introduce platform
dependency as well (case-insensitivity on Windows).
Previous Comments:
------------------------------------------------------------------------
[2004-08-01 01:00:05] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
------------------------------------------------------------------------
[2004-07-20 02:47:41] [EMAIL PROTECTED]
what happens if you do:
copy("C:\\file.gif", "C:\\file.gif")
------------------------------------------------------------------------
[2004-07-19 15:06:24] zet at male dot ru
Description:
------------
When i copy file with function copy, like this
copy("C:\file.gif", "C:\file.gif"), file was break. His size is 0.
Reproduce code:
---------------
copy("C:\file.gif", "C:\file.gif");
Expected result:
----------------
IMHO file must stand without changes.
Actual result:
--------------
File changed. His size is 0.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=29257&edit=1