mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 06:42:32 +08:00
malloc:if malloc filed need print leak memory detatls
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
This commit is contained in:
@@ -378,6 +378,9 @@ FAR void *mm_malloc(FAR struct mm_heap_s *heap, size_t size)
|
||||
# endif
|
||||
# ifdef CONFIG_MM_DUMP_DETAILS_ON_FAILURE
|
||||
mm_memdump(heap, &dump);
|
||||
mwarn("Dump leak memory(thread exit, but memory not free):\n");
|
||||
dump.pid = PID_MM_LEAK;
|
||||
mm_memdump(heap, &dump);
|
||||
# endif
|
||||
#endif
|
||||
#ifdef CONFIG_MM_PANIC_ON_FAILURE
|
||||
|
||||
Reference in New Issue
Block a user