projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2a3f279
)
af_packet: do not accept mc address smaller then dev->addr_len in packet_mc_add()
author
Jiri Pirko
<jpirko@redhat.com>
Wed, 24 Feb 2010 23:57:04 +0000
(23:57 +0000)
committer
David S. Miller
<davem@davemloft.net>
Fri, 26 Feb 2010 12:18:34 +0000
(
04:18
-0800)
There is no point of accepting an address of smaller length than dev->addr_len
here. Therefore change this for stonger check.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/packet/af_packet.c
patch
|
blob
|
blame
|
history
diff --git
a/net/packet/af_packet.c
b/net/packet/af_packet.c
index 2f0369367ee0ca26c249efb44a08f42f4469385a..e2d1def708414bf3564b319d27d588b80237c247 100644
(file)
--- a/
net/packet/af_packet.c
+++ b/
net/packet/af_packet.c
@@
-1734,7
+1734,7
@@
static int packet_mc_add(struct sock *sk, struct packet_mreq_max *mreq)
goto done;
err = -EINVAL;
- if (mreq->mr_alen
>
dev->addr_len)
+ if (mreq->mr_alen
!=
dev->addr_len)
goto done;
err = -ENOBUFS;