[1.2.2] [Regression] Fix segfault when GC is ON