From: Witold Kręcicki Date: Thu, 12 Dec 2019 21:55:57 +0000 (+0100) Subject: netmgr: set sock->listening in isc__nm_async_tcplisten always, even in case of errors... X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f527a5ed01bcd08d505db26c6098bb5d77b7fa9c;p=thirdparty%2Fbind9.git netmgr: set sock->listening in isc__nm_async_tcplisten always, even in case of errors, to avoid a deadlock. In case of a failure it will be cleared anyway --- diff --git a/lib/isc/netmgr/tcp.c b/lib/isc/netmgr/tcp.c index d6ba3f4a999..58e88c9a981 100644 --- a/lib/isc/netmgr/tcp.c +++ b/lib/isc/netmgr/tcp.c @@ -335,9 +335,8 @@ isc__nm_async_tcplisten(isc__networker_t *worker, isc__netievent_t *ev0) { } } - atomic_store(&sock->listening, true); - done: + atomic_store(&sock->listening, true); LOCK(&sock->lock); SIGNAL(&sock->cond); UNLOCK(&sock->lock);