mirror of
https://github.com/php/php-src.git
synced 2025-08-16 22:18:50 +02:00
revert copy patch.
This commit is contained in:
parent
e707137ed3
commit
f95651e338
1 changed files with 0 additions and 6 deletions
|
@ -1700,12 +1700,6 @@ PHPAPI int php_copy_file(char *src, char *dest TSRMLS_DC)
|
||||||
{
|
{
|
||||||
php_stream *srcstream = NULL, *deststream = NULL;
|
php_stream *srcstream = NULL, *deststream = NULL;
|
||||||
int ret = FAILURE;
|
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);
|
srcstream = php_stream_open_wrapper(src, "rb", STREAM_DISABLE_OPEN_BASEDIR | REPORT_ERRORS, NULL);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue