mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-26 06:04:14 +08:00
tulip_core.c : out-of-bounds check.
Array index 'j' is used before limits check. Suggest put limit check before index use. Signed-off-by : <Ameenali023@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
ab3971b1e7
commit
b57578b3d5
@ -589,7 +589,7 @@ static void tulip_tx_timeout(struct net_device *dev)
|
|||||||
(unsigned int)tp->rx_ring[i].buffer1,
|
(unsigned int)tp->rx_ring[i].buffer1,
|
||||||
(unsigned int)tp->rx_ring[i].buffer2,
|
(unsigned int)tp->rx_ring[i].buffer2,
|
||||||
buf[0], buf[1], buf[2]);
|
buf[0], buf[1], buf[2]);
|
||||||
for (j = 0; buf[j] != 0xee && j < 1600; j++)
|
for (j = 0; ((j < 1600) && buf[j] != 0xee); j++)
|
||||||
if (j < 100)
|
if (j < 100)
|
||||||
pr_cont(" %02x", buf[j]);
|
pr_cont(" %02x", buf[j]);
|
||||||
pr_cont(" j=%d\n", j);
|
pr_cont(" j=%d\n", j);
|
||||||
|
Loading…
Reference in New Issue
Block a user