- Squelch EADDRNOTAVAIL errors when the interface goes away,

this omits 'can't assign requested address' errors unless
  verbosity is set to a high value.


git-svn-id: file:///svn/unbound/trunk@4931 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
Wouter Wijngaards 2018-10-05 06:29:05 +00:00
parent 1c08a2ba55
commit 945452bff4
2 changed files with 10 additions and 1 deletions

View file

@ -1,3 +1,8 @@
5 October 2018: Wouter
- Squelch EADDRNOTAVAIL errors when the interface goes away,
this omits 'can't assign requested address' errors unless
verbosity is set to a high value.
2 October 2018: Wouter
- updated contrib/fastrpz.patch to apply for this version
- dnscrypt.c removed sizeof to get array bounds.

View file

@ -565,7 +565,11 @@ create_udp_sock(int family, int socktype, struct sockaddr* addr,
if(family==AF_INET6 && errno==EINVAL)
*noproto = 1;
else if(errno != EADDRINUSE &&
!(errno == EACCES && verbosity < 4 && !listen)) {
!(errno == EACCES && verbosity < 4 && !listen)
#ifdef EADDRNOTAVAIL
&& !(errno == EADDRNOTAVAIL && verbosity < 4 && !listen)
#endif
) {
log_err_addr("can't bind socket", strerror(errno),
(struct sockaddr_storage*)addr, addrlen);
}