Skip to content

Commit 5c91587

Browse files
committed
Fix memory leak
1 parent e467d5a commit 5c91587

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

components/robusto/base/src/system/robusto_system.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ void *robusto_spi_realloc(void *ptr, size_t size)
114114
void *new_ptr = heap_caps_realloc(ptr, size, MALLOC_CAP_SPIRAM);
115115
if (!new_ptr) {
116116
ROB_LOGW(system_log_prefix, "robusto_spi_realloc failed to realloc %u bytes.", (unsigned)size);
117-
return robusto_realloc(new_ptr, size);
117+
return robusto_realloc(ptr, size);
118118
} else {
119119
return new_ptr;
120120
}

0 commit comments

Comments
 (0)