net/radvd: adapt previous patch to check for proper return value

PR:		270757
Reported by:	Franco Fichtner <franco@opnsense.org>
This commit is contained in:
Babak Farrokhi 2023-04-11 19:12:08 +02:00
parent f737b9c517
commit 132939b5ee
2 changed files with 2 additions and 2 deletions

View file

@ -1,6 +1,6 @@
PORTNAME= radvd
PORTVERSION= 2.19
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= net
MASTER_SITES= http://www.litech.org/radvd/dist/

View file

@ -20,7 +20,7 @@
+ }
+
+ if (setsockopt(sock, IPPROTO_IPV6, IPV6_JOIN_GROUP,
+ &mreq, sizeof(mreq)) < 0 && !iface->state_info.ready) {
+ &mreq, sizeof(mreq)) < 0 && errno != EADDRINUSE) {
+ flog(LOG_ERR, "can't join ipv6-allrouters on %s", iface->props.name);
+ return (-1);
+ }