diff options
author | Paul Pluzhnikov <ppluzhnikov@google.com> | 2014-03-10 14:02:07 -0700 |
---|---|---|
committer | Paul Pluzhnikov <ppluzhnikov@google.com> | 2014-03-10 14:02:07 -0700 |
commit | 9590be99606bd4903f8527affccc7c0957a9515d (patch) | |
tree | 129dbe46c6bfd6004804fad25c153f8cd6fd2b50 /sysdeps/generic | |
parent | 8eb1716c9108c987004e886e37d33296032d8663 (diff) | |
download | glibc-9590be99606bd4903f8527affccc7c0957a9515d.zip glibc-9590be99606bd4903f8527affccc7c0957a9515d.tar.gz glibc-9590be99606bd4903f8527affccc7c0957a9515d.tar.bz2 |
For Google b/8315591, experimental implementation of dlopen_with_offset.
Diffstat (limited to 'sysdeps/generic')
-rw-r--r-- | sysdeps/generic/ldsodefs.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/sysdeps/generic/ldsodefs.h b/sysdeps/generic/ldsodefs.h index caa5f1d..5e7224b 100644 --- a/sysdeps/generic/ldsodefs.h +++ b/sysdeps/generic/ldsodefs.h @@ -600,8 +600,9 @@ struct rtld_global_ro const struct r_found_version *, int, int, struct link_map *); int (*_dl_check_caller) (const void *, enum allowmask); - void *(*_dl_open) (const char *file, int mode, const void *caller_dlopen, - Lmid_t nsid, int argc, char *argv[], char *env[]); + void *(*_dl_open) (const char *file, off_t offset, int mode, + const void *caller_dlopen, Lmid_t nsid, + int argc, char *argv[], char *env[]); void (*_dl_close) (void *map); void *(*_dl_tls_get_addr_soft) (struct link_map *); #ifdef HAVE_DL_DISCOVER_OSVERSION @@ -856,10 +857,12 @@ int _dl_catch_exception (struct dl_exception *exception, libc_hidden_proto (_dl_catch_exception) /* Open the shared object NAME and map in its segments. + ELF header is at OFFSET into the file. LOADER's DT_RPATH is used in searching for NAME. If the object is already opened, returns its existing map. */ extern struct link_map *_dl_map_object (struct link_map *loader, const char *name, + off_t offset, int type, int trace_mode, int mode, Lmid_t nsid) attribute_hidden; @@ -1116,8 +1119,9 @@ extern int _dl_check_caller (const void *caller, enum allowmask mask) /* Open the shared object NAME, relocate it, and run its initializer if it hasn't already been run. MODE is as for `dlopen' (see <dlfcn.h>). If the object is already opened, returns its existing map. */ -extern void *_dl_open (const char *name, int mode, const void *caller, - Lmid_t nsid, int argc, char *argv[], char *env[]) +extern void *_dl_open (const char *name, off_t offset, int mode, + const void *caller, Lmid_t nsid, + int argc, char *argv[], char *env[]) attribute_hidden; /* Free or queue for freeing scope OLD. If other threads might be |