summaryrefslogtreecommitdiff
path: root/usr.sbin/snmpd
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2013-03-11 17:40:12 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2013-03-11 17:40:12 +0000
commit039b61c058ed96cb3a888f9dee21bca7997f0a39 (patch)
treee836c8501a7ce9ead08db116a7d3413b4c79e0ff /usr.sbin/snmpd
parent11f71752a566cd212ee320890884ad5c2b6dcc64 (diff)
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/snmpd')
-rw-r--r--usr.sbin/snmpd/control.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/snmpd/control.c b/usr.sbin/snmpd/control.c
index 29cba914e62..f508d6bf56b 100644
--- a/usr.sbin/snmpd/control.c
+++ b/usr.sbin/snmpd/control.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: control.c,v 1.17 2012/11/29 14:53:24 yasuoka Exp $ */
+/* $OpenBSD: control.c,v 1.18 2013/03/11 17:40:11 deraadt Exp $ */
/*
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -157,7 +157,8 @@ control_accept(int listenfd, short event, void *arg)
event_del(&cs->cs_ev);
evtimer_add(&cs->cs_evt, &evtpause);
- } else if (errno != EWOULDBLOCK && errno != EINTR)
+ } else if (errno != EWOULDBLOCK && errno != EINTR &&
+ errno != ECONNABORTED)
log_warn("control_accept: accept");
return;
}