hyanantha               Thu Oct 24 05:48:40 2002 EDT

  Modified files:              (Branch: PHP_4_2_0)
    /php4/ext/ftp       php_ftp.c 
  Log:
  NetWare related changes/modifications.
  
  
Index: php4/ext/ftp/php_ftp.c
diff -u php4/ext/ftp/php_ftp.c:1.53.2.1 php4/ext/ftp/php_ftp.c:1.53.2.2
--- php4/ext/ftp/php_ftp.c:1.53.2.1     Fri Mar 29 20:58:24 2002
+++ php4/ext/ftp/php_ftp.c      Thu Oct 24 05:48:40 2002
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_ftp.c,v 1.53.2.1 2002/03/30 01:58:24 mfischer Exp $ */
+/* $Id: php_ftp.c,v 1.53.2.2 2002/10/24 09:48:40 hyanantha Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -24,6 +24,16 @@
 
 #include "php.h"
 
+#ifdef NETWARE
+#ifdef USE_WINSOCK
+#include <novsock2.h>
+#else
+#ifndef NEW_LIBC
+#include <sys/socket.h>
+#endif
+#endif
+#endif
+
 #if HAVE_FTP
 
 #include "ext/standard/info.h"
@@ -482,7 +492,7 @@
                RETURN_FALSE;
        }
 
-#ifdef PHP_WIN32
+#if defined(PHP_WIN32) || defined(NETWARE)  /* On Windows and NetWare, the file 
+should always be opened in binary mode */
        if ((outfp = VCWD_FOPEN(local, "wb")) == NULL) {
 #else
        if ((outfp = VCWD_FOPEN(local, "w")) == NULL) {
@@ -557,7 +567,7 @@
        ZEND_FETCH_RESOURCE(ftp, ftpbuf_t*, &z_ftp, -1, le_ftpbuf_name, le_ftpbuf);
        XTYPE(xtype, mode);
 
-#ifdef PHP_WIN32
+#if defined(PHP_WIN32) || defined(NETWARE)  /* On Windows and NetWare, the file 
+should always be opened in binary mode */
        if ((infp = VCWD_FOPEN(local, "rb")) == NULL) {
 #else
        if ((infp = VCWD_FOPEN(local, "r")) == NULL) {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to