From aa2189295e4e531d05733d60bfd697c7a962b100 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Sun, 18 Mar 2018 19:52:39 +0100 Subject: hurd: Fix boot with statically-linked exec server * sysdeps/mach/hurd/i386/init-first.c (init): Also find ELF headers by oneself when the pointer given in D is nul (as set by ext2fs). --- sysdeps/mach/hurd/i386/init-first.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sysdeps/mach/hurd/i386') diff --git a/sysdeps/mach/hurd/i386/init-first.c b/sysdeps/mach/hurd/i386/init-first.c index f4a4df33de..226de02a99 100644 --- a/sysdeps/mach/hurd/i386/init-first.c +++ b/sysdeps/mach/hurd/i386/init-first.c @@ -107,7 +107,7 @@ init1 (int argc, char *arg0, ...) /* If we are the bootstrap task started by the kernel, then after the environment pointers there is no Hurd data block; the argument strings start there. */ - if ((void *) d == argv[0]) + if ((void *) d == argv[0] || d->phdr == NULL) { #ifndef SHARED /* With a new enough linker (binutils-2.23 or better), -- cgit 1.4.1