]> granicus.if.org Git - php/commitdiff
fix Win32 & Netware build
authorAntony Dovgal <tony2001@php.net>
Thu, 28 Oct 2004 05:05:39 +0000 (05:05 +0000)
committerAntony Dovgal <tony2001@php.net>
Thu, 28 Oct 2004 05:05:39 +0000 (05:05 +0000)
main/streams/plain_wrapper.c

index a7f7088fc1655daf270ef00810760b6e2b7f4b05..28e41a26618d144986a8bf3dd705806cd4ac7107 100644 (file)
@@ -1024,6 +1024,7 @@ static int php_plain_files_rename(php_stream_wrapper *wrapper, char *url_from, c
                        struct stat sb;
                        if (php_copy_file(url_from, url_to TSRMLS_CC) == SUCCESS) {
                                if (VCWD_STAT(url_from, &sb) == 0) {
+#if !defined(TSRM_WIN32) && !defined(NETWARE)                                  
                                        if (VCWD_CHMOD(url_to, sb.st_mode)) {
                                                if (errno == EPERM) {
                                                        php_error_docref2(NULL TSRMLS_CC, url_from, url_to, E_WARNING, "%s", strerror(errno));
@@ -1042,6 +1043,7 @@ static int php_plain_files_rename(php_stream_wrapper *wrapper, char *url_from, c
                                                php_error_docref2(NULL TSRMLS_CC, url_from, url_to, E_WARNING, "%s", strerror(errno));
                                                return 0;
                                        }
+#endif
                                        VCWD_UNLINK(url_from);
                                        return 1;
                                }