We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f4a5c17 commit 6305d48Copy full SHA for 6305d48
1 file changed
py/gc.c
@@ -667,6 +667,9 @@ void gc_free(void *ptr) {
667
if (ptr == NULL) {
668
GC_EXIT();
669
} else {
670
+ if (MP_STATE_MEM(gc_pool_start) == 0) {
671
+ reset_into_safe_mode(GC_ALLOC_OUTSIDE_VM);
672
+ }
673
// get the GC block number corresponding to this pointer
674
assert(VERIFY_PTR(ptr));
675
size_t block = BLOCK_FROM_PTR(ptr);
0 commit comments