blob: e9ab881fc30721bad44f32ce9431b1fd1fbd981e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
$NetBSD: patch-do,v 1.2 2013/05/29 11:11:12 wiz Exp $
--- libgc/headers.c.orig 2012-12-05 17:44:36.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;
|