diff options
| author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-03-11 16:13:03 +0000 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-03-11 16:13:03 +0000 |
| commit | e631dfd1d68d523cfb9dad891bf7db3960128cd4 (patch) | |
| tree | 3a45c0cee91d8b8e605c89d14a9a5ed8afc0bd8b /libexec/rtld-elf | |
| parent | 01d81b94aaf749cfedf4c71c644be5004b19e047 (diff) | |
MFH (r251810): fix installation from read-only .OBJDIR
MFH (r255384): add PRIVATELIB for internal-use shred libraries
MFH (r255385, r255413): add a stock libmap32.conf
MFH (r255765): always support directory mapping; rewrite libmap man page
Notes
svn path=/stable/9/; revision=263031
Diffstat (limited to 'libexec/rtld-elf')
| -rw-r--r-- | libexec/rtld-elf/libmap.c | 2 | ||||
| -rw-r--r-- | libexec/rtld-elf/libmap.h | 2 | ||||
| -rw-r--r-- | libexec/rtld-elf/rtld.c | 10 |
3 files changed, 5 insertions, 9 deletions
diff --git a/libexec/rtld-elf/libmap.c b/libexec/rtld-elf/libmap.c index 1efc8bc5de51..8eab5047185c 100644 --- a/libexec/rtld-elf/libmap.c +++ b/libexec/rtld-elf/libmap.c @@ -396,7 +396,6 @@ lm_find (const char *p, const char *f) /* Given a libmap translation list and a library name, return the replacement library, or NULL */ -#ifdef COMPAT_32BIT char * lm_findn (const char *p, const char *f, const int n) { @@ -413,7 +412,6 @@ lm_findn (const char *p, const char *f, const int n) free(s); return (t); } -#endif static char * lml_find (struct lm_list *lmh, const char *f) diff --git a/libexec/rtld-elf/libmap.h b/libexec/rtld-elf/libmap.h index 53b2ba1ec0bf..54b4a2fe2e82 100644 --- a/libexec/rtld-elf/libmap.h +++ b/libexec/rtld-elf/libmap.h @@ -5,6 +5,4 @@ int lm_init (char *); void lm_fini (void); char * lm_find (const char *, const char *); -#ifdef COMPAT_32BIT char * lm_findn (const char *, const char *, const int); -#endif diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index 5100d2b2e0e9..c3d4272fba7e 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -2612,12 +2612,14 @@ rtld_exit(void) lock_release(rtld_bind_lock, &lockstate); } +/* + * Iterate over a search path, translate each element, and invoke the + * callback on the result. + */ static void * path_enumerate(const char *path, path_enum_proc callback, void *arg) { -#ifdef COMPAT_32BIT const char *trans; -#endif if (path == NULL) return (NULL); @@ -2627,13 +2629,11 @@ path_enumerate(const char *path, path_enum_proc callback, void *arg) char *res; len = strcspn(path, ":;"); -#ifdef COMPAT_32BIT trans = lm_findn(NULL, path, len); if (trans) res = callback(trans, strlen(trans), arg); else -#endif - res = callback(path, len, arg); + res = callback(path, len, arg); if (res != NULL) return (res); |
