mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2024-10-01 01:35:54 -04:00
14 lines
475 B
Diff
14 lines
475 B
Diff
|
diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
|
||
|
index 86b3e2f..9c80212 100644
|
||
|
--- a/net/packet/af_packet.c
|
||
|
+++ b/net/packet/af_packet.c
|
||
|
@@ -3820,6 +3820,8 @@
|
||
|
rb->frames_per_block = req->tp_block_size/req->tp_frame_size;
|
||
|
if (unlikely(rb->frames_per_block <= 0))
|
||
|
goto out;
|
||
|
+ if (unlikely(req->tp_block_size > UINT_MAX / req->tp_block_nr))
|
||
|
+ goto out;
|
||
|
if (unlikely((rb->frames_per_block * req->tp_block_nr) !=
|
||
|
req->tp_frame_nr))
|
||
|
goto out;
|