opnsense-src/libexec/rtld-elf/tests/libval/libval.c
Kyle Evans d9c543b6b0 rtld: add a test for RTLD_DEEPBIND
This tests that with RTLD_DEEPBIND, symbols are looked up in all of the
object's needed objects before the global object.

PR:		275393
Reviewed by:	kib
Sponsored by:	NetApp, Inc.
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D42843
2023-11-30 19:26:09 -06:00

26 lines
238 B
C

/*-
*
* Copyright (C) 2023 NetApp, Inc.
*
* SPDX-License-Identifier: BSD-2-Clause
*
*/
static int val;
int get_value(void);
void set_value(int);
int
get_value(void)
{
return (val);
}
void
set_value(int nval)
{
val = nval;
}