summaryrefslogtreecommitdiff
path: root/ldso/dynlink.c
diff options
context:
space:
mode:
Diffstat (limited to 'ldso/dynlink.c')
-rw-r--r--ldso/dynlink.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ldso/dynlink.c b/ldso/dynlink.c
index 5361b844..d20dbd87 100644
--- a/ldso/dynlink.c
+++ b/ldso/dynlink.c
@@ -1768,9 +1768,9 @@ void *dlopen(const char *file, int mode)
}
/* First load handling */
- if (!p->relocated) {
+ if (!p->deps) {
load_deps(p);
- if ((mode & RTLD_LAZY)) {
+ if (!p->relocated && (mode & RTLD_LAZY)) {
prepare_lazy(p);
if (p->deps) for (i=0; p->deps[i]; i++)
if (!p->deps[i]->relocated)