sync with OpenBSD -current
This commit is contained in:
parent
cc6742f14d
commit
f913a3fe74
59 changed files with 478 additions and 318 deletions
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: dl_printf.c,v 1.22 2022/01/08 06:49:41 guenther Exp $ */
|
||||
/* $OpenBSD: dl_printf.c,v 1.23 2024/01/22 02:08:31 deraadt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1993
|
||||
|
@ -69,7 +69,7 @@ static void kprintn(int, u_long, int);
|
|||
static void kdoprnt(int, const char *, va_list);
|
||||
static void _dl_flushbuf(void);
|
||||
|
||||
static void putcharfd(int, int );
|
||||
static void putcharfd(int, int);
|
||||
|
||||
static void
|
||||
putcharfd(int c, int fd)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: dlfcn.c,v 1.116 2023/12/19 16:13:22 deraadt Exp $ */
|
||||
/* $OpenBSD: dlfcn.c,v 1.117 2024/01/22 02:08:31 deraadt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB
|
||||
|
@ -119,7 +119,7 @@ dlopen(const char *libname, int flags)
|
|||
/* this add_object should not be here, XXX */
|
||||
_dl_add_object(object);
|
||||
|
||||
DL_DEB(("head [%s]\n", object->load_name ));
|
||||
DL_DEB(("head [%s]\n", object->load_name));
|
||||
|
||||
if ((failed = _dl_load_dep_libs(object, obj_flags, 0)) == 1) {
|
||||
_dl_real_close(object);
|
||||
|
@ -127,7 +127,7 @@ dlopen(const char *libname, int flags)
|
|||
_dl_errno = DL_CANT_LOAD_OBJ;
|
||||
} else {
|
||||
int err;
|
||||
DL_DEB(("tail %s\n", object->load_name ));
|
||||
DL_DEB(("tail %s\n", object->load_name));
|
||||
if (_dl_traceld) {
|
||||
_dl_show_objects(object);
|
||||
_dl_unload_shlib(object);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: loader.c,v 1.222 2024/01/19 14:16:41 deraadt Exp $ */
|
||||
/* $OpenBSD: loader.c,v 1.223 2024/01/22 02:08:31 deraadt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB
|
||||
|
@ -157,7 +157,7 @@ _dl_run_all_dtors(void)
|
|||
}
|
||||
for (node = _dl_objects;
|
||||
node != NULL;
|
||||
node = node->next ) {
|
||||
node = node->next) {
|
||||
if ((node->dyn.fini || node->dyn.fini_array) &&
|
||||
(OBJECT_REF_CNT(node) == 0) &&
|
||||
(node->status & STAT_INIT_DONE) &&
|
||||
|
@ -174,7 +174,7 @@ _dl_run_all_dtors(void)
|
|||
|
||||
for (node = _dl_objects;
|
||||
node != NULL;
|
||||
node = node->next ) {
|
||||
node = node->next) {
|
||||
if (node->status & STAT_FINI_READY) {
|
||||
fini_complete = 0;
|
||||
node->status |= STAT_FINI_DONE;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: resolve.c,v 1.101 2024/01/16 19:07:31 deraadt Exp $ */
|
||||
/* $OpenBSD: resolve.c,v 1.102 2024/01/22 02:08:31 deraadt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 Per Fogelstrom, Opsycon AB
|
||||
|
@ -321,7 +321,7 @@ _dl_finalize_object(const char *objname, Elf_Dyn *dynp, Elf_Phdr *phdrp,
|
|||
gnu_hash = dynp->d_un.d_val;
|
||||
dynp++;
|
||||
}
|
||||
DL_DEB((" flags %s = 0x%x\n", objname, object->obj_flags ));
|
||||
DL_DEB((" flags %s = 0x%x\n", objname, object->obj_flags));
|
||||
object->obj_type = objtype;
|
||||
|
||||
if (_dl_loading_object == NULL) {
|
||||
|
@ -441,7 +441,7 @@ _dl_finalize_object(const char *objname, Elf_Dyn *dynp, Elf_Phdr *phdrp,
|
|||
if (object->load_object == object)
|
||||
DL_DEB(("head %s\n", object->load_name));
|
||||
DL_DEB(("obj %s has %s as head\n", object->load_name,
|
||||
_dl_loading_object->load_name ));
|
||||
_dl_loading_object->load_name));
|
||||
object->refcount = 0;
|
||||
object->opencount = 0; /* # dlopen() & exe */
|
||||
object->grprefcount = 0;
|
||||
|
@ -733,7 +733,7 @@ found:
|
|||
|
||||
if (ref_sym != NULL && ref_sym->st_size != 0 &&
|
||||
(ref_sym->st_size != sl.sl_out.sym->st_size) &&
|
||||
(ELF_ST_TYPE(sl.sl_out.sym->st_info) != STT_FUNC) ) {
|
||||
(ELF_ST_TYPE(sl.sl_out.sym->st_info) != STT_FUNC)) {
|
||||
_dl_printf("%s:%s: %s : WARNING: "
|
||||
"symbol(%s) size mismatch, relink your program\n",
|
||||
__progname, req_obj->load_name, sl.sl_out.obj->load_name,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue