From: florian Date: Wed, 15 Aug 2018 16:48:20 +0000 (+0000) Subject: SIOCGIFNETMASK_IN6 failing just means that someone delete the address X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=1347ce87f45dac76c7725befe8ef2bfdbeb66d18;p=openbsd SIOCGIFNETMASK_IN6 failing just means that someone delete the address we are currently looking at. No need to fatal. Found the hard way by naddy --- diff --git a/usr.sbin/rad/frontend.c b/usr.sbin/rad/frontend.c index 0a5a982ba9e..c452a845fd3 100644 --- a/usr.sbin/rad/frontend.c +++ b/usr.sbin/rad/frontend.c @@ -1,4 +1,4 @@ -/* $OpenBSD: frontend.c,v 1.15 2018/08/03 13:14:46 florian Exp $ */ +/* $OpenBSD: frontend.c,v 1.16 2018/08/15 16:48:20 florian Exp $ */ /* * Copyright (c) 2018 Florian Obser @@ -828,7 +828,7 @@ get_interface_prefixes(struct ra_iface *ra_iface, struct ra_prefix_conf memcpy(&ifr6.ifr_addr, sin6, sizeof(ifr6.ifr_addr)); if (ioctl(ioctlsock, SIOCGIFNETMASK_IN6, (caddr_t)&ifr6) < 0) - fatal("SIOCGIFNETMASK_IN6"); + continue; /* addr got deleted while we were looking */ prefixlen = in6_mask2prefixlen(&((struct sockaddr_in6 *) &ifr6.ifr_addr)->sin6_addr);