From 75a34d18a0708049689533e03e3770ffeeb0764b Mon Sep 17 00:00:00 2001 From: Adrien Ricciardi Date: Mon, 13 Nov 2023 16:45:32 +0100 Subject: [PATCH] libraries: net: can: Fixed length computation in tpl_can_fill_pdu_info(). Signed-off-by: Adrien Ricciardi --- libraries/net/can/tpl_can_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/net/can/tpl_can_core.c b/libraries/net/can/tpl_can_core.c index abb14e401..d82ce7599 100644 --- a/libraries/net/can/tpl_can_core.c +++ b/libraries/net/can/tpl_can_core.c @@ -200,5 +200,5 @@ void tpl_can_fill_pdu_info(Can_PduType *can_pdu, PduInfoType *pdu_info, Can_IdTy can_pdu->length = (uint8) payload_length; pdu_info->SduDataPtr = (uint8 *) can_pdu; - pdu_info->SduLength = sizeof(can_pdu) + payload_length; + pdu_info->SduLength = sizeof(Can_PduType) + payload_length; }