addr: Only attempt Address resolution on non parsable lines
commita8b8a1ee99fa843a5937b4d2a5973c444a4311e0
authorDavid Goulet <dgoulet@torproject.org>
Tue, 30 Jun 2020 16:05:56 +0000 (30 12:05 -0400)
committerDavid Goulet <dgoulet@torproject.org>
Tue, 30 Jun 2020 16:05:56 +0000 (30 12:05 -0400)
treef595427737af934dea8e860fbcabdd777890c0c6
parent89c26f4cfd03fa9d26caa99ecf24258e25fc56ea
addr: Only attempt Address resolution on non parsable lines

In get_address_from_config(), we would attempt to resolve an Address line that
is not from the requested family but that line could be a valid address from
another family (v4 vs v6).

This makes it that we don't attempt to resolve a valid address from another
family.

Found with unit test config/find_my_address_mixed.

Fixed in #33235
Related to #33233

Signed-off-by: David Goulet <dgoulet@torproject.org>
src/app/config/resolve_addr.c