Understand IFF_MULTICAST flag on ifaces in Linux
Unfortunately, some interfaces support multicast but do not have this flag set, so we use it only as a positive hint. Thanks to Clint Armstrong for noticing the problem.
This commit is contained in:
parent
2eadd36fa0
commit
16a3254c4c
1 changed files with 3 additions and 0 deletions
|
@ -436,6 +436,9 @@ nl_parse_link(struct nlmsghdr *h, int scan)
|
||||||
else
|
else
|
||||||
f.flags |= IF_MULTIACCESS; /* NBMA */
|
f.flags |= IF_MULTIACCESS; /* NBMA */
|
||||||
|
|
||||||
|
if (fl & IFF_MULTICAST)
|
||||||
|
f.flags |= IF_MULTICAST;
|
||||||
|
|
||||||
ifi = if_update(&f);
|
ifi = if_update(&f);
|
||||||
|
|
||||||
if (!scan)
|
if (!scan)
|
||||||
|
|
Loading…
Reference in a new issue