summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ftp-proxy
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2013-03-11 17:40:09 +0000
committerderaadt <deraadt@openbsd.org>2013-03-11 17:40:09 +0000
commit62e3c2528255beec34fe0acd77e74b042a0926c6 (patch)
tree1c7e4070f2f682e9d9017be26794ca4197437d0e /usr.sbin/ftp-proxy
parentWhen binding a lease, check for and clear out any 'zombie' routes (diff)
downloadwireguard-openbsd-62e3c2528255beec34fe0acd77e74b042a0926c6.tar.xz
wireguard-openbsd-62e3c2528255beec34fe0acd77e74b042a0926c6.zip
handle ECONNABORTED errors from accept(). In many code blocks they can be
ignored silently and without aborting, much like EINTR and EWOULDBLOCK are. ok's from various maintainers of these directories...
Diffstat (limited to 'usr.sbin/ftp-proxy')
-rw-r--r--usr.sbin/ftp-proxy/ftp-proxy.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/ftp-proxy/ftp-proxy.c b/usr.sbin/ftp-proxy/ftp-proxy.c
index 38a81e3f707..936ba06c106 100644
--- a/usr.sbin/ftp-proxy/ftp-proxy.c
+++ b/usr.sbin/ftp-proxy/ftp-proxy.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ftp-proxy.c,v 1.26 2013/03/10 21:28:26 benno Exp $ */
+/* $OpenBSD: ftp-proxy.c,v 1.27 2013/03/11 17:40:11 deraadt Exp $ */
/*
* Copyright (c) 2004, 2005 Camiel Dobbelaar, <cd@sentia.nl>
@@ -435,7 +435,9 @@ handle_connection(const int listen_fd, short event, void *arg)
event_del(&listen_ev);
evtimer_add(&pause_accept_ev, &pause);
- }
+ } else if (errno != EWOULDBLOCK && errno != EINTR &&
+ errno != ECONNABORTED)
+ logmsg(LOG_CRIT, "accept() failed: %s", strerror(errno));
return;
}