]> granicus.if.org Git - php/commitdiff
copy() now creates the destination file with mode 0777 again. this is
authorThies C. Arntzen <thies@php.net>
Tue, 13 Jun 2000 15:48:38 +0000 (15:48 +0000)
committerThies C. Arntzen <thies@php.net>
Tue, 13 Jun 2000 15:48:38 +0000 (15:48 +0000)
the way it used to be in PHP 3

ext/standard/file.c

index fb34ad6f60e37035aa4106262cd08d632311d595..b081e529e69623c8714e3e5ecc03384273219b79 100644 (file)
@@ -1685,7 +1685,7 @@ PHP_FUNCTION(copy)
 #ifdef PHP_WIN32
        if ((fd_t=V_OPEN((Z_STRVAL_PP(target),_O_WRONLY|_O_CREAT|_O_TRUNC|_O_BINARY,_S_IREAD|_S_IWRITE)))==-1){
 #else
-       if ((fd_t=V_CREAT(Z_STRVAL_PP(target),0700))==-1) {
+       if ((fd_t=V_CREAT(Z_STRVAL_PP(target),0777))==-1) {
 #endif
                php_error(E_WARNING,"Unable to create '%s':  %s", Z_STRVAL_PP(target), strerror(errno));
                close(fd_s);