From e20f5adc121c0776d621ff7ce90a03ae7fbe25a8 Mon Sep 17 00:00:00 2001 From: iysheng Date: Thu, 14 Apr 2022 11:54:53 +0800 Subject: [PATCH] Fix compile warning 'prio' may be used uninitialized --- osal/cmsis_os/cmsis_os2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osal/cmsis_os/cmsis_os2.c b/osal/cmsis_os/cmsis_os2.c index 3890fb723..a6ea54418 100644 --- a/osal/cmsis_os/cmsis_os2.c +++ b/osal/cmsis_os/cmsis_os2.c @@ -156,7 +156,7 @@ osThreadId_t osThreadNew(osThreadFunc_t func, k_err_t err; uint32_t stack_size = K_TASK_STK_SIZE_MIN; k_task_t* taskId = NULL; - k_prio_t prio; + k_prio_t prio = osPriorityNormal; if (attr && func) { if (attr->priority != osPriorityNone) {