aboutsummaryrefslogtreecommitdiff
path: root/networking/ftpgetput.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2014-03-16 10:05:53 +0000
committerRon Yorston <rmy@pobox.com>2014-03-16 10:05:53 +0000
commit637c0772f7a1cdb08ff26e0added72470f6e392b (patch)
tree6efe049162e1752b700469491e8f34da4e59600d /networking/ftpgetput.c
parente8c9f63c8e618d85104369a4c588129b165851e2 (diff)
downloadbusybox-w32-637c0772f7a1cdb08ff26e0added72470f6e392b.tar.gz
busybox-w32-637c0772f7a1cdb08ff26e0added72470f6e392b.tar.bz2
busybox-w32-637c0772f7a1cdb08ff26e0added72470f6e392b.zip
wget: add fseek calls to make ftp work; enable ftpget/ftpput
Diffstat (limited to 'networking/ftpgetput.c')
-rw-r--r--networking/ftpgetput.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/networking/ftpgetput.c b/networking/ftpgetput.c
index 8283366cc..0670b2141 100644
--- a/networking/ftpgetput.c
+++ b/networking/ftpgetput.c
@@ -100,6 +100,9 @@ static int ftpcmd(const char *s1, const char *s2)
100 fprintf(control_stream, (s2 ? "%s %s\r\n" : "%s %s\r\n"+3), 100 fprintf(control_stream, (s2 ? "%s %s\r\n" : "%s %s\r\n"+3),
101 s1, s2); 101 s1, s2);
102 fflush(control_stream); 102 fflush(control_stream);
103#if ENABLE_PLATFORM_MINGW32
104 fseek(control_stream, 0L, SEEK_CUR);
105#endif
103 } 106 }
104 107
105 do { 108 do {
@@ -108,6 +111,9 @@ static int ftpcmd(const char *s1, const char *s2)
108 ftp_die(NULL); 111 ftp_die(NULL);
109 } 112 }
110 } while (!isdigit(buf[0]) || buf[3] != ' '); 113 } while (!isdigit(buf[0]) || buf[3] != ' ');
114#if ENABLE_PLATFORM_MINGW32
115 fseek(control_stream, 0L, SEEK_CUR);
116#endif
111 117
112 buf[3] = '\0'; 118 buf[3] = '\0';
113 n = xatou(buf); 119 n = xatou(buf);