diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2023-11-18 16:26:18 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2023-11-18 16:26:18 +0000 |
commit | eebaec8bf69b2db1088ab7a84b8bc96a3d02473e (patch) | |
tree | 01c4cdb241357ce61e341e655dd01bce0c5d750d /lib/csu/boot.h | |
parent | 9039430940e09de13f4467d9fd1a12296a6746f4 (diff) |
crt0 uses a helper function in a MD src/libexec/ld.so .h file (rather than
reproducing the relevant defines and code in a different place) to perform
minor relocations. If things go very wrong, it would call _dl_exit() --
a locally defined crt0 function which is syscall exit(2). We don't need
to call exit(2) for this obscure case which doesn't happen and provides no
debugging information. An 'abort' is going to provide better information.
So let's change the function name to _dso_abort() and make it a single
illegal instruction.
ok guenther
Diffstat (limited to 'lib/csu/boot.h')
-rw-r--r-- | lib/csu/boot.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/csu/boot.h b/lib/csu/boot.h index 72cbfee007b..da6d424bdeb 100644 --- a/lib/csu/boot.h +++ b/lib/csu/boot.h @@ -1,4 +1,4 @@ -/* $OpenBSD: boot.h,v 1.34 2022/10/21 18:14:09 deraadt Exp $ */ +/* $OpenBSD: boot.h,v 1.35 2023/11/18 16:26:15 deraadt Exp $ */ /* * Copyright (c) 1998 Per Fogelstrom, Opsycon AB @@ -40,7 +40,7 @@ #include <machine/reloc.h> __dead -void _dl_exit(int); +void _csu_abort(void); #include "archdep.h" |