From f6e5db226ff68cde2d5f9b5a0cd5b93070828d19 Mon Sep 17 00:00:00 2001 From: Alexander Kabaev Date: Thu, 22 Dec 2005 16:42:38 +0000 Subject: Initialize object dagmembers list before checking version dependencies. --- libexec/rtld-elf/rtld.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'libexec') diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index e3790046cc2a..01ea4f664699 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -1762,16 +1762,14 @@ dlopen(const char *name, int mode) mode &= RTLD_MODEMASK; if (*old_obj_tail != NULL) { /* We loaded something new. */ assert(*old_obj_tail == obj); - result = load_needed_objects(obj); + init_dag(obj); if (result != -1) result = rtld_verify_versions(&obj->dagmembers); if (result != -1 && ld_tracing) goto trace; - if (result == -1 || - (init_dag(obj), relocate_objects(obj, mode == RTLD_NOW, - &obj_rtld)) == -1) { + (relocate_objects(obj, mode == RTLD_NOW, &obj_rtld)) == -1) { obj->dl_refcount--; unref_dag(obj); if (obj->refcount == 0) -- cgit v1.3