From 39414b19827649b97f306bf33e90e502db2f08f5 Mon Sep 17 00:00:00 2001 From: antonio-pasini <63703444+antonio-pasini@users.noreply.github.com> Date: Sat, 9 Nov 2024 09:42:54 +0100 Subject: [PATCH] Update lv_freertos.c; skip mutex delete if not initialized cfr. issue #7219, lw_draw_sw_deinit() called twice. --- src/osal/lv_freertos.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/osal/lv_freertos.c b/src/osal/lv_freertos.c index 3a0c2bf1e34c..3744f585524f 100644 --- a/src/osal/lv_freertos.c +++ b/src/osal/lv_freertos.c @@ -176,6 +176,8 @@ lv_result_t lv_mutex_unlock(lv_mutex_t * pxMutex) lv_result_t lv_mutex_delete(lv_mutex_t * pxMutex) { + if(pxMutex->xIsInitialized == pdFALSE) + return LV_RESULT_INVALID; vSemaphoreDelete(pxMutex->xMutex); pxMutex->xIsInitialized = pdFALSE;