diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1997-11-25 08:10:35 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1997-11-25 08:10:35 +0000 |
commit | 633b07b1cfe970da2ebf009fd0ffccb1b0cf03bd (patch) | |
tree | fc4a00b415df51db5c02cace6d8ec5dd4bf8ee0f /usr.bin/ftp/util.c | |
parent | c832ead9f4cf227ddd0e22bfa999ee402c054a63 (diff) |
prompting error; pr#352, blair@nac.net
Diffstat (limited to 'usr.bin/ftp/util.c')
-rw-r--r-- | usr.bin/ftp/util.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/usr.bin/ftp/util.c b/usr.bin/ftp/util.c index 6d63b5ff6f6..a6659994a9a 100644 --- a/usr.bin/ftp/util.c +++ b/usr.bin/ftp/util.c @@ -1,4 +1,4 @@ -/* $OpenBSD: util.c,v 1.15 1997/09/15 04:57:54 millert Exp $ */ +/* $OpenBSD: util.c,v 1.16 1997/11/25 08:10:34 deraadt Exp $ */ /* $NetBSD: util.c,v 1.12 1997/08/18 10:20:27 lukem Exp $ */ /* @@ -35,7 +35,7 @@ */ #ifndef lint -static char rcsid[] = "$OpenBSD: util.c,v 1.15 1997/09/15 04:57:54 millert Exp $"; +static char rcsid[] = "$OpenBSD: util.c,v 1.16 1997/11/25 08:10:34 deraadt Exp $"; #endif /* not lint */ /* @@ -444,6 +444,7 @@ confirm(cmd, file) if (!interactive || confirmrest) return (1); +top: fprintf(ttyout, "%s %s? ", cmd, file); (void)fflush(ttyout); if (fgets(line, sizeof(line), stdin) == NULL) @@ -464,9 +465,7 @@ confirm(cmd, file) break; default: fprintf(ttyout, "n, y, p, a, are the only acceptable commands!\n"); - fprintf(ttyout, "%s %s? ", cmd, file); - fgets(line, sizeof(line), stdin); - confirm(cmd, file); + goto top; break; } return (1); |