=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ftp/ftp.c,v retrieving revision 1.55 retrieving revision 1.56 diff -c -r1.55 -r1.56 *** src/usr.bin/ftp/ftp.c 2003/12/16 21:46:22 1.55 --- src/usr.bin/ftp/ftp.c 2004/07/20 03:50:25 1.56 *************** *** 1,4 **** ! /* $OpenBSD: ftp.c,v 1.55 2003/12/16 21:46:22 deraadt Exp $ */ /* $NetBSD: ftp.c,v 1.27 1997/08/18 10:20:23 lukem Exp $ */ /* --- 1,4 ---- ! /* $OpenBSD: ftp.c,v 1.56 2004/07/20 03:50:25 deraadt Exp $ */ /* $NetBSD: ftp.c,v 1.27 1997/08/18 10:20:23 lukem Exp $ */ /* *************** *** 60,66 **** */ #if !defined(lint) && !defined(SMALL) ! static char rcsid[] = "$OpenBSD: ftp.c,v 1.55 2003/12/16 21:46:22 deraadt Exp $"; #endif /* not lint and not SMALL */ #include --- 60,66 ---- */ #if !defined(lint) && !defined(SMALL) ! static char rcsid[] = "$OpenBSD: ftp.c,v 1.56 2004/07/20 03:50:25 deraadt Exp $"; #endif /* not lint and not SMALL */ #include *************** *** 117,125 **** FILE *cin, *cout; char * ! hookup(host, port) ! char *host; ! char *port; { int s, len, tos, error; static char hostnamebuf[MAXHOSTNAMELEN]; --- 117,123 ---- FILE *cin, *cout; char * ! hookup(char *host, char *port) { int s, len, tos, error; static char hostnamebuf[MAXHOSTNAMELEN]; *************** *** 270,277 **** } void ! cmdabort(notused) ! int notused; { alarmtimer(0); --- 268,274 ---- } void ! cmdabort(int notused) { alarmtimer(0); *************** *** 326,333 **** char reply_string[BUFSIZ]; /* first line of previous reply */ int ! getreply(expecteof) ! int expecteof; { char current_line[BUFSIZ]; /* last line of previous reply */ int c, n, line; --- 323,329 ---- char reply_string[BUFSIZ]; /* first line of previous reply */ int ! getreply(int expecteof) { char current_line[BUFSIZ]; /* last line of previous reply */ int c, n, line; *************** *** 449,456 **** jmp_buf sendabort; void ! abortsend(notused) ! int notused; { alarmtimer(0); --- 445,451 ---- jmp_buf sendabort; void ! abortsend(int notused) { alarmtimer(0); *************** *** 462,470 **** } void ! sendrequest(cmd, local, remote, printnames) ! const char *cmd, *local, *remote; ! int printnames; { struct stat st; int c, d; --- 457,464 ---- } void ! sendrequest(const char *cmd, const char *local, const char *remote, ! int printnames) { struct stat st; int c, d; *************** *** 744,751 **** jmp_buf recvabort; void ! abortrecv(notused) ! int notused; { alarmtimer(0); --- 738,744 ---- jmp_buf recvabort; void ! abortrecv(int notused) { alarmtimer(0); *************** *** 757,765 **** } void ! recvrequest(cmd, local, remote, lmode, printnames, ignorespecial) ! const char *cmd, * volatile local, *remote, *lmode; ! int printnames, ignorespecial; { FILE * volatile fout, * volatile din; int (* volatile closefunc)(FILE *); --- 750,757 ---- } void ! recvrequest(const char *cmd, const char * volatile local, const char *remote, ! const char *lmode, int printnames, int ignorespecial) { FILE * volatile fout, * volatile din; int (* volatile closefunc)(FILE *); *************** *** 1135,1141 **** * otherwise the server's connect may fail. */ int ! initconn() { char *p, *a; int result = ERROR, len, tmpno = 0; --- 1127,1133 ---- * otherwise the server's connect may fail. */ int ! initconn(void) { char *p, *a; int result = ERROR, len, tmpno = 0; *************** *** 1523,1530 **** } FILE * ! dataconn(lmode) ! const char *lmode; { union sockunion from; int s, fromlen = myctladdr.su_len; --- 1515,1521 ---- } FILE * ! dataconn(const char *lmode) { union sockunion from; int s, fromlen = myctladdr.su_len; *************** *** 1553,1560 **** } void ! psummary(notused) ! int notused; { int save_errno = errno; --- 1544,1550 ---- } void ! psummary(int notused) { int save_errno = errno; *************** *** 1564,1571 **** } void ! psabort(notused) ! int notused; { alarmtimer(0); --- 1554,1560 ---- } void ! psabort(int notused) { alarmtimer(0); *************** *** 1573,1580 **** } void ! pswitch(flag) ! int flag; { sig_t oldintr; static struct comvars { --- 1562,1568 ---- } void ! pswitch(int flag) { sig_t oldintr; static struct comvars { *************** *** 1661,1668 **** } void ! abortpt(notused) ! int notused; { alarmtimer(0); --- 1649,1655 ---- } void ! abortpt(int notused) { alarmtimer(0); *************** *** 1675,1682 **** } void ! proxtrans(cmd, local, remote) ! const char *cmd, *local, *remote; { volatile sig_t oldintr; int prox_type, nfnd; --- 1662,1668 ---- } void ! proxtrans(const char *cmd, const char *local, const char *remote) { volatile sig_t oldintr; int prox_type, nfnd; *************** *** 1797,1805 **** } void ! reset(argc, argv) ! int argc; ! char *argv[]; { struct pollfd pfd[1]; int nfnd = 1; --- 1783,1789 ---- } void ! reset(int argc, char *argv[]) { struct pollfd pfd[1]; int nfnd = 1; *************** *** 1818,1825 **** } char * ! gunique(local) ! const char *local; { static char new[MAXPATHLEN]; char *cp = strrchr(local, '/'); --- 1802,1808 ---- } char * ! gunique(const char *local) { static char new[MAXPATHLEN]; char *cp = strrchr(local, '/'); *************** *** 1864,1871 **** } void ! abort_remote(din) ! FILE *din; { char buf[BUFSIZ]; int nfnd; --- 1847,1853 ---- } void ! abort_remote(FILE *din) { char buf[BUFSIZ]; int nfnd;