]> granicus.if.org Git - php/commitdiff
MFH: revert copy patch.
authorIlia Alshanetsky <iliaa@php.net>
Sun, 27 Mar 2005 15:53:59 +0000 (15:53 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Sun, 27 Mar 2005 15:53:59 +0000 (15:53 +0000)
ext/standard/file.c

index 1d688cfe8d12fc47fd556af3c0d240f52aa5d2be..b1ad6f742da82fce0664fa8579cf65b0bb994068 100644 (file)
@@ -2141,12 +2141,6 @@ PHPAPI int php_copy_file(char *src, char *dest TSRMLS_DC)
 {
        php_stream *srcstream = NULL, *deststream = NULL;
        int ret = FAILURE;
-       struct stat src_s, dest_s;
-
-       /* safety check to ensure that source & destination files are not the same file */
-       if (stat(src, &src_s) || (stat(dest, &dest_s) == 0 && src_s.st_ino == dest_s.st_ino)) {
-               return ret;
-       }
 
        srcstream = php_stream_open_wrapper(src, "rb",
                                STREAM_DISABLE_OPEN_BASEDIR | REPORT_ERRORS,