We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 71173fa + cd1dc14 commit 67d8d36Copy full SHA for 67d8d36
ports/raspberrypi/lwip_src/lwip_mem.c
@@ -8,14 +8,20 @@
8
#include <string.h>
9
#include "lib/tlsf/tlsf.h"
10
#include "lwip_mem.h"
11
+#include "shared-bindings/microcontroller/__init__.h"
12
#include "supervisor/port_heap.h"
13
14
void *lwip_heap_malloc(size_t size) {
- return port_malloc(size, true);
15
+ common_hal_mcu_disable_interrupts();
16
+ void *ptr = port_malloc(size, true);
17
+ common_hal_mcu_enable_interrupts();
18
+ return ptr;
19
}
20
21
void lwip_heap_free(void *ptr) {
22
23
port_free(ptr);
24
25
26
27
void *lwip_heap_calloc(size_t num, size_t size) {
0 commit comments