mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2025-01-27 00:24:07 +01:00
monitor: Fix issue with enabling PACKET_MR_ALLMULTI option
This commit is contained in:
parent
da5841201e
commit
df718dda94
@ -1178,13 +1178,11 @@ static struct l_io *open_packet(const char *name)
|
|||||||
mr.mr_type = PACKET_MR_ALLMULTI;
|
mr.mr_type = PACKET_MR_ALLMULTI;
|
||||||
|
|
||||||
if (setsockopt(fd, SOL_PACKET, PACKET_ADD_MEMBERSHIP,
|
if (setsockopt(fd, SOL_PACKET, PACKET_ADD_MEMBERSHIP,
|
||||||
&mr, sizeof(mr) < 0)) {
|
&mr, sizeof(mr)) < 0) {
|
||||||
perror("Failed to enable all multicast");
|
perror("Failed to enable all multicast");
|
||||||
if (errno != EINVAL) {
|
|
||||||
close(fd);
|
close(fd);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
io = l_io_new(fd);
|
io = l_io_new(fd);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user