Commit 60f054f
committed
dns: print failure message when EAI_AGAIN retries are exhausted
When getaddrinfo returns EAI_AGAIN ("Temporary failure in name
resolution"), iprange retries the request up to 20 times. After the last
retry, the request was silently completed without any final diagnostic.
On systems without network connectivity (e.g. distribution package build
VMs), this causes the user to see twenty "will be retried" lines and
then nothing, even though the command exits non-zero. It also breaks
tests.d/64-dns-failure-exit-status, which greps stderr for "failed
permanently" — a string only emitted on the EAI_NONAME path.
Mirror the EAI_NONAME branch and emit a "failed permanently after
retries" message before completing the request, so the user (and the
test) get a clear final error regardless of whether the resolver reached
a server.
Fixes #421 parent a745967 commit 60f054f
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
| 150 | + | |
| 151 | + | |
150 | 152 | | |
151 | 153 | | |
152 | 154 | | |
| |||
0 commit comments