summaryrefslogtreecommitdiff
path: root/libexec
diff options
context:
space:
mode:
authorDale Rahn <drahn@cvs.openbsd.org>2006-05-07 15:36:44 +0000
committerDale Rahn <drahn@cvs.openbsd.org>2006-05-07 15:36:44 +0000
commite7dde5a9556d8f0a8b6db09742710382a028ad4e (patch)
treeb912650993779a1436855a409702bf65ae13a472 /libexec
parent8c7a41d9129f11745c699fcb4723d7a6bc24de25 (diff)
Initialize oprebind_data so that unintialized memory is not referenced.
caught by niallo
Diffstat (limited to 'libexec')
-rw-r--r--libexec/ld.so/prebind/objarray.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libexec/ld.so/prebind/objarray.c b/libexec/ld.so/prebind/objarray.c
index c319b6d5a55..1b86d2c3a85 100644
--- a/libexec/ld.so/prebind/objarray.c
+++ b/libexec/ld.so/prebind/objarray.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: objarray.c,v 1.3 2006/05/06 20:31:05 drahn Exp $ */
+/* $OpenBSD: objarray.c,v 1.4 2006/05/07 15:36:43 drahn Exp $ */
/*
* Copyright (c) 2006 Dale Rahn <drahn@dalerahn.com>
*
@@ -838,6 +838,7 @@ elf_add_object(struct elf_object *object, int objtype)
objarray[objarray_cnt].obj = object;
objarray[objarray_cnt].id0 = arc4random(); /* XXX FIX */
objarray[objarray_cnt].id1 = arc4random();
+ objarray[objarray_cnt].oprebind_data = NULL;
objarray_cnt++;
elf_add_object_curbin_list(object);