Rahul Bhansali 0490d69d58 examples/l3fwd: fix buffer overflow in Tx
This patch fixes the stack buffer overflow error reported
from AddressSanitizer.
Function send_packetsx4() tries to access out of bound data
from rte_mbuf and fill it into TX buffer even in the case
where no pending packets (len = 0).
Performance impact:- No

ASAN error report:-
==819==ERROR: AddressSanitizer: stack-buffer-overflow on address
0xffffe2c0dcf0 at pc 0x0000005e791c bp 0xffffe2c0d7e0 sp 0xffffe2c0d800
READ of size 8 at 0xffffe2c0dcf0 thread T0
 #0 0x5e7918 in send_packetsx4 ../examples/l3fwd/l3fwd_common.h:251
 #1 0x5e7918 in send_packets_multi ../examples/l3fwd/l3fwd_neon.h:226

Fixes: 96ff445371e0 ("examples/l3fwd: reorganise and optimize LPM code path")
Cc: stable@dpdk.org

Signed-off-by: Rahul Bhansali <rbhansali@marvell.com>
Reviewed-by: Conor Walsh <conor.walsh@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2022-03-15 01:14:56 +01:00
..
2022-01-11 12:16:53 +01:00
2021-10-24 13:37:43 +02:00
2022-01-11 12:16:53 +01:00
2021-10-22 18:15:38 +02:00
2021-10-22 18:15:38 +02:00
2022-02-12 12:07:48 +01:00
2021-10-22 18:15:38 +02:00
2022-01-11 12:16:53 +01:00
2021-10-22 18:15:38 +02:00
2022-02-12 12:07:48 +01:00
2022-01-11 12:16:53 +01:00
2021-10-22 18:15:38 +02:00