From 853d840ec92883df414bfb444ca678487a830cf9 Mon Sep 17 00:00:00 2001 From: SG Date: Tue, 15 Nov 2022 23:27:30 +1000 Subject: [PATCH] Crash when malloc in ISR --- furi/core/memmgr_heap.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/furi/core/memmgr_heap.c b/furi/core/memmgr_heap.c index ac51b4a20..95afd3087 100644 --- a/furi/core/memmgr_heap.c +++ b/furi/core/memmgr_heap.c @@ -340,6 +340,10 @@ void* pvPortMalloc(size_t xWantedSize) { void* pvReturn = NULL; size_t to_wipe = xWantedSize; + if(FURI_IS_ISR()) { + furi_crash("malloc in ISR"); + } + #ifdef HEAP_PRINT_DEBUG BlockLink_t* print_heap_block = NULL; #endif