CLEANUP: resolvers: get rid of single-iteration loop in resolv_get_ip_from_response()
authorWilly Tarreau <w@1wt.eu>
Fri, 22 Oct 2021 06:34:14 +0000 (08:34 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 22 Oct 2021 06:34:14 +0000 (08:34 +0200)
commitdbb0bb59e3c14c1b231b6931b9609d7ae94e0a4f
treeb3246f9e7da517cf01da7295e00e3113e57974b5
parent0b222476062d76a1660892a81e9a97962dce1582
CLEANUP: resolvers: get rid of single-iteration loop in resolv_get_ip_from_response()

In issue 1424 Coverity reports that the loop increment is unreachable,
which is true, the list_for_each_entry() was replaced with a for loop,
but it was already not needed and was instead used as a convenient
construct for a single iteration lookup. Let's get rid of all this
now and replace the loop with an "if" statement.
src/resolvers.c