summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libexec/ftpd/ftpd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libexec/ftpd/ftpd.c b/libexec/ftpd/ftpd.c
index 9740c2789f6..fb032b5e642 100644
--- a/libexec/ftpd/ftpd.c
+++ b/libexec/ftpd/ftpd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ftpd.c,v 1.21 1996/09/29 22:11:50 millert Exp $ */
+/* $OpenBSD: ftpd.c,v 1.22 1996/10/15 12:29:27 deraadt Exp $ */
/* $NetBSD: ftpd.c,v 1.15 1995/06/03 22:46:47 mycroft Exp $ */
/*
@@ -1749,6 +1749,8 @@ passive()
reply(530, "Please login with USER and PASS");
return;
}
+ if (pdata >= 0)
+ close(pdata);
pdata = socket(AF_INET, SOCK_STREAM, 0);
if (pdata < 0) {
perror_reply(425, "Can't open passive connection");