CVS update: php3
| From: | jim | Date: | Sat, 12 Jun 1999 20:41:40 +0000 |
| Subject: | CVS update: php3 | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-6913@lists.php.net to get a copy of this message | ||
Date: Saturday June 12, 1999 @ 16:41
Author: jim
Update of /repository/php3
In directory php:/tmp/cvs-serv24135
Modified Files:
fopen-wrappers.c
Log Message:
Apparently this makes some FTP servers happier, and I don't see how it could hurt.
Index: php3/fopen-wrappers.c
diff -u php3/fopen-wrappers.c:1.62 php3/fopen-wrappers.c:1.63
--- php3/fopen-wrappers.c:1.62 Tue Jun 8 20:16:00 1999
+++ php3/fopen-wrappers.c Sat Jun 12 16:41:39 1999
@@ -27,7 +27,7 @@
| Jim Winstead <jimw@php.net> |
+----------------------------------------------------------------------+
*/
-/* $Id: fopen-wrappers.c,v 1.62 1999/06/09 00:16:00 steffann Exp $ */
+/* $Id: fopen-wrappers.c,v 1.63 1999/06/12 20:41:39 jim Exp $ */
#ifdef THREAD_SAFE
#include "tls.h"
@@ -748,6 +748,16 @@
return NULL;
}
+ /* set the connection to be binary */
+ SOCK_WRITE("TYPE I\n", *socketd);
+ result = _php3_getftpresult(*socketd);
+ if (result > 299 || result < 200) {
+ free_url(resource);
+ SOCK_FCLOSE(*socketd);
+ *socketd = 0;
+ return NULL;
+ }
+
/* find out the size of the file (verifying it exists) */
SOCK_WRITE("SIZE ", *socketd);
SOCK_WRITE(resource->path, *socketd);
@@ -777,15 +787,6 @@
}
}
- /* set the connection to be binary */
- SOCK_WRITE("TYPE I\n", *socketd);
- result = _php3_getftpresult(*socketd);
- if (result > 299 || result < 200) {
- free_url(resource);
- SOCK_FCLOSE(*socketd);
- *socketd = 0;
- return NULL;
- }
/* set up the passive connection */
SOCK_WRITE("PASV\n", *socketd);
while (SOCK_FGETS(tmp_line, 256, *socketd) &&