mirror of
https://github.com/espressif/esp-idf
synced 2025-03-10 17:49:10 -04:00
Merge branch 'fix/heap-calloc-fail-wrong-size_v5.1' into 'release/v5.1'
fix(heap): Wrong size propagated in alloc fail callback of heap_caps_calloc() (backport v5.1) See merge request espressif/esp-idf!30091
This commit is contained in:
commit
9abd010153
@ -507,7 +507,7 @@ HEAP_IRAM_ATTR void *heap_caps_calloc( size_t n, size_t size, uint32_t caps)
|
||||
|
||||
|
||||
if (!ptr && size > 0){
|
||||
heap_caps_alloc_failed(size, caps, __func__);
|
||||
heap_caps_alloc_failed(n * size, caps, __func__);
|
||||
}
|
||||
|
||||
return ptr;
|
||||
|
Loading…
x
Reference in New Issue
Block a user