Correctly filter \r\r\n during ascii receives (from Steve Jacobson).
authorGregory Minshall <minshall@ucbvax.Berkeley.EDU>
Wed, 7 May 1986 12:20:51 +0000 (04:20 -0800)
committerGregory Minshall <minshall@ucbvax.Berkeley.EDU>
Wed, 7 May 1986 12:20:51 +0000 (04:20 -0800)
SCCS-vsn: usr.bin/ftp/ftp.c 5.13

usr/src/usr.bin/ftp/ftp.c

index a50c663..22677c4 100644 (file)
@@ -5,7 +5,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)ftp.c      5.12 (Berkeley) %G%";
+static char sccsid[] = "@(#)ftp.c      5.13 (Berkeley) %G%";
 #endif not lint
 
 #include "ftp_var.h"
 #endif not lint
 
 #include "ftp_var.h"
@@ -740,7 +740,7 @@ recvrequest(cmd, local, remote, mode)
 
        case TYPE_A:
                while ((c = getc(din)) != EOF) {
 
        case TYPE_A:
                while ((c = getc(din)) != EOF) {
-                       if (c == '\r') {
+                       while (c == '\r') {
                                while (hash && (bytes >= hashbytes)) {
                                        (void) putchar('#');
                                        (void) fflush(stdout);
                                while (hash && (bytes >= hashbytes)) {
                                        (void) putchar('#');
                                        (void) fflush(stdout);