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

Merge pull request #2757 from BernardXiong/fix_warning

[kernel] skip warning when disable debug.
This commit is contained in:
Bernard Xiong 2019-06-08 14:56:12 +08:00 committed by GitHub
commit 849d62dd57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -262,7 +262,10 @@ void rt_object_init(struct rt_object *object,
struct rt_object *obj; struct rt_object *obj;
obj = rt_list_entry(node, struct rt_object, list); obj = rt_list_entry(node, struct rt_object, list);
RT_ASSERT(obj != object); if (obj) /* skip warning when disable debug */
{
RT_ASSERT(obj != object);
}
} }
/* leave critical */ /* leave critical */
rt_exit_critical(); rt_exit_critical();