Skip to content

Commit e8302b2

Browse files
committed
Merge pull request #11626 from yuyichao/module-parent
Only visit module parent when it is not NULL
2 parents 539c818 + bc5b600 commit e8302b2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/gc.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1567,7 +1567,9 @@ NOINLINE static int gc_mark_module(jl_module_t *m, int d)
15671567
refyoung |= gc_push_root(m->constant_table, d);
15681568
}
15691569

1570-
refyoung |= gc_push_root(m->parent, d);
1570+
if (m->parent) {
1571+
refyoung |= gc_push_root(m->parent, d);
1572+
}
15711573

15721574
return refyoung;
15731575
}

0 commit comments

Comments
 (0)