summaryrefslogtreecommitdiffstats
path: root/lib/libfetch/ftp.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libfetch/ftp.c')
-rw-r--r--lib/libfetch/ftp.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/libfetch/ftp.c b/lib/libfetch/ftp.c
index e6c520f..bb34aed 100644
--- a/lib/libfetch/ftp.c
+++ b/lib/libfetch/ftp.c
@@ -300,13 +300,12 @@ _ftp_transfer(int cd, char *oper, char *file,
* is IMHO the one and only weak point in the FTP protocol.
*/
ln = last_reply;
- for (p = ln + 3; *p && *p != '('; p++)
+ for (p = ln + 3; *p && !isdigit(*p); p++)
/* nothing */ ;
if (!*p) {
e = 999;
goto ouch;
}
- p++;
switch (e) {
case FTP_PASSIVE_MODE:
case FTP_LPASSIVE_MODE:
OpenPOWER on IntegriCloud