diff options
| author | Matthew N. Dodd <mdodd@FreeBSD.org> | 2003-09-13 21:43:08 +0000 |
|---|---|---|
| committer | Matthew N. Dodd <mdodd@FreeBSD.org> | 2003-09-13 21:43:08 +0000 |
| commit | 4402996dea6d9df64ac8c395f31b5d90d364207b (patch) | |
| tree | 919ac9ae9921903ef959120200906c83c32193b7 /libexec | |
| parent | be2c4e5415af82b1d0e782dcfcb21e61c9452a91 (diff) | |
Notes
Diffstat (limited to 'libexec')
| -rw-r--r-- | libexec/rtld-elf/libmap.c | 6 | ||||
| -rw-r--r-- | libexec/rtld-elf/libmap.h | 2 | ||||
| -rw-r--r-- | libexec/rtld-elf/rtld.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/libexec/rtld-elf/libmap.c b/libexec/rtld-elf/libmap.c index bdb9151180061..56e04fdaf209c 100644 --- a/libexec/rtld-elf/libmap.c +++ b/libexec/rtld-elf/libmap.c @@ -41,7 +41,7 @@ static struct lm_list * lmp_init (char *); #define iseol(c) (((c) == '#') || ((c) == '\0') || \ ((c) == '\n') || ((c) == '\r')) -void +int lm_init (void) { FILE *fp; @@ -55,7 +55,7 @@ lm_init (void) TAILQ_INIT(&lmp_head); if ((fp = fopen(_PATH_LIBMAP_CONF, "r")) == NULL) - return; + return (1); p = NULL; while ((cp = fgets(line, MAXPATHLEN + 1, fp)) != NULL) { @@ -128,7 +128,7 @@ lm_init (void) lm_add(p, f, t); } fclose(fp); - return; + return (0); } static void diff --git a/libexec/rtld-elf/libmap.h b/libexec/rtld-elf/libmap.h index 8228ef8edcb1e..f42df44d29e86 100644 --- a/libexec/rtld-elf/libmap.h +++ b/libexec/rtld-elf/libmap.h @@ -2,6 +2,6 @@ * $FreeBSD$ */ -void lm_init (void); +int lm_init (void); void lm_fini (void); char * lm_find (const char *, const char *); diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index e8cbf24cffff5..801fa4b2cbe6e 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -342,7 +342,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_proc, Obj_Entry **objp) #ifdef WITH_LIBMAP if (!libmap_disable) - lm_init(); + libmap_disable = (bool)lm_init(); #endif dbg("loading LD_PRELOAD libraries"); |
