From: Tomas Krizek Date: Tue, 8 Sep 2020 08:53:57 +0000 (+0200) Subject: daemon/worker: simplify condition X-Git-Tag: v5.2.0~15^2~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5ea57a3426af5c2a30b47f3d262fbd8219818ee3;p=thirdparty%2Fknot-resolver.git daemon/worker: simplify condition --- diff --git a/daemon/worker.c b/daemon/worker.c index 66bbe98a0..c1aa13d35 100644 --- a/daemon/worker.c +++ b/daemon/worker.c @@ -1612,10 +1612,11 @@ int worker_submit(struct session *session, const struct sockaddr *peer, knot_pkt /* Ignore badly formed queries. */ if ((ret != kr_ok() && ret != kr_error(EMSGSIZE)) || (is_query == is_outgoing)) { - if (!is_outgoing) + if (!is_outgoing) { the_worker->stats.dropped += 1; - if (!is_outgoing && http_ctx) - queue_pop(http_ctx->streams); + if (http_ctx) + queue_pop(http_ctx->streams); + } return kr_error(EILSEQ); }