4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-01-19 18:23:32 +08:00

[kservice]:修复关闭RT_USING_CONSOLE和RT_USING_FINSH编译有警告的BUG (#8575)

This commit is contained in:
BreederBai 2024-03-03 23:12:35 +08:00 committed by GitHub
parent aa04a59805
commit cb154ae30a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View File

@ -289,6 +289,7 @@ rt_err_t rt_susp_list_enqueue(rt_list_t *susp_list, rt_thread_t thread, int ipc_
*/
void rt_susp_list_print(rt_list_t *list)
{
#ifdef RT_USING_CONSOLE
rt_sched_lock_level_t slvl;
struct rt_thread *thread;
struct rt_list_node *node;
@ -305,6 +306,9 @@ void rt_susp_list_print(rt_list_t *list)
}
rt_sched_unlock(slvl);
#else
(void)list;
#endif
}

View File

@ -1716,7 +1716,7 @@ rt_err_t rt_backtrace_thread(rt_thread_t thread)
return rc;
}
#ifdef RT_USING_LIBC
#if defined(RT_USING_LIBC) && defined(RT_USING_FINSH)
#include <stdlib.h> /* for string service */
static void cmd_backtrace(int argc, char** argv)