diff options
author | Poul-Henning Kamp <phk@FreeBSD.org> | 1995-05-24 18:35:10 +0000 |
---|---|---|
committer | Poul-Henning Kamp <phk@FreeBSD.org> | 1995-05-24 18:35:10 +0000 |
commit | e7b2fe43e042e49ae2a0073db6e59c870fedf8ff (patch) | |
tree | f96f89cece06c0f7498e20b9dcc85028284638ea /usr.sbin/sysinstall | |
parent | 0b81ddd0c25e943df7c6b50201e85cb6377b7780 (diff) | |
download | src-e7b2fe43e042e49ae2a0073db6e59c870fedf8ff.tar.gz src-e7b2fe43e042e49ae2a0073db6e59c870fedf8ff.zip |
Close the transfer socket.
Notes
Notes:
svn path=/head/; revision=8729
Diffstat (limited to 'usr.sbin/sysinstall')
-rw-r--r-- | usr.sbin/sysinstall/ftp.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.sbin/sysinstall/ftp.c b/usr.sbin/sysinstall/ftp.c index 1de9902060a8..0564aea12c55 100644 --- a/usr.sbin/sysinstall/ftp.c +++ b/usr.sbin/sysinstall/ftp.c @@ -6,7 +6,7 @@ * this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp * ---------------------------------------------------------------------------- * - * $Id: ftp.c,v 1.5 1995/05/24 17:49:14 jkh Exp $ + * $Id: ftp.c,v 1.6 1995/05/24 18:21:48 jkh Exp $ * */ @@ -146,6 +146,7 @@ FtpInit() return ftp; memset(ftp, 0, sizeof *ftp); ftp->fd_ctrl = -1; + ftp->fd_extr = -1; ftp->fd_debug = -1; ftp->state = init; return ftp; @@ -301,6 +302,7 @@ FtpGet(FTP_t ftp, char *file) if (i > 299) return -1; ftp->state = xfer; + ftp->fd_xfer = s; return s; } else { return -1; @@ -312,6 +314,8 @@ FtpEOF(FTP_t ftp) { if (ftp->state != xfer) return botch(ftp,"FtpEOF","xfer"); + close(ftp->fd_extr); + ftp->fd_extr = -1; ftp->state = isopen; return get_a_number(ftp,0); } |