mirror of
https://github.com/espressif/esp-sr.git
synced 2025-09-15 15:28:44 +08:00
bugfix(c_speech_feature): alloc from SRAM when PSRAM is disabled
This commit is contained in:
parent
d05f268bae
commit
7b43d3706a
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -277,7 +277,11 @@ void esp_mn_active_commands_print(void)
|
|||||||
void *_esp_mn_calloc_(int n, int size)
|
void *_esp_mn_calloc_(int n, int size)
|
||||||
{
|
{
|
||||||
#ifdef ESP_PLATFORM
|
#ifdef ESP_PLATFORM
|
||||||
return heap_caps_calloc(n, size, MALLOC_CAP_SPIRAM);
|
void *data = heap_caps_calloc(n, size, MALLOC_CAP_SPIRAM);
|
||||||
|
if (data == NULL) {
|
||||||
|
data = calloc(n, size);
|
||||||
|
}
|
||||||
|
return data;
|
||||||
#else
|
#else
|
||||||
return calloc(n, size);
|
return calloc(n, size);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user