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

index 5178ac6e2ed1f851df614c7bae5352d0b99caca9..6ef83af5e8f1b3a9336e74f26d21db6b3148b85f 100644 (file)
@@ -1619,12 +1619,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, NULL);