FreeRTOS / FreeRTOS-Cellular-Interface

FreeRTOS Cellular Interface implementation of the 3GPP TS v27.007 standard.
MIT License
85 stars 59 forks source link

Memory leak in Cellular_Cleanup #119

Closed renesas-adam-benson closed 1 year ago

renesas-adam-benson commented 1 year ago

The task that is created in cellular_pktio on a Cellular_Init call is never deleted on Cellular_Cleanup/_Cellular_PktioShutdown.

https://github.com/FreeRTOS/FreeRTOS-Cellular-Interface/blob/936d4f73b0e162912e3c41595a455319c495f90a/source/cellular_pktio.c#L1187

chinglee-iot commented 1 year ago

Hi Adam,

Platform_CreateDetachedThread is supposed to delete the thread info after the thread function returns. The implementation in demo can be referenced. https://github.com/FreeRTOS/FreeRTOS/blob/391c79958f635ee5476dcf2774dab59e2b151eff/FreeRTOS-Plus/Demo/FreeRTOS_Cellular_Interface_Windows_Simulator/Common/cellular_platform.c#L64-L73

renesas-adam-benson commented 1 year ago

@chinglee-iot thanks for the response. Missed this when looking through it, closing the issue.