From 7a3cb283ec8ed1e7c54b169f7b82355c35a174dd Mon Sep 17 00:00:00 2001 From: Dong Heng Date: Thu, 20 Sep 2018 21:32:56 +0800 Subject: [PATCH] fix(heap): Fix heap dump error when input file has no dir --- components/heap/src/esp_heap_trace.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/components/heap/src/esp_heap_trace.c b/components/heap/src/esp_heap_trace.c index 00efa5c2..e17e8ed4 100644 --- a/components/heap/src/esp_heap_trace.c +++ b/components/heap/src/esp_heap_trace.c @@ -124,6 +124,8 @@ void heap_trace_dump(void) const char *file = rindex(mem2_blk->file, '/'); if (file) file++; + else + file = mem2_blk->file; ESP_EARLY_LOGI(TAG, HEAP_INFO " caller file %s line %d", HEAP_INFO_PARAM(p), file, mem2_blk->line); }