2016-01-21 23:40:00 +01:00

14 lines
471 B
Plaintext

$NetBSD: patch-do,v 1.3 2014/11/30 08:40:51 spz Exp $
--- libgc/headers.c.orig 2014-09-22 13:23:05.000000000 +0000
+++ libgc/headers.c
@@ -139,6 +139,8 @@ void GC_init_headers()
register unsigned i;
GC_all_nils = (bottom_index *)GC_scratch_alloc((word)sizeof(bottom_index));
+ if (GC_all_nils == NULL)
+ ABORT("out of memory");
BZERO(GC_all_nils, sizeof(bottom_index));
for (i = 0; i < TOP_SZ; i++) {
GC_top_index[i] = GC_all_nils;