summaryrefslogtreecommitdiffstats
path: root/crypto/dso/dso_dl.c
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2005-12-30 22:53:59 +0000
committerAndy Polyakov <appro@openssl.org>2005-12-30 22:53:59 +0000
commit68b64fb6102737bf84de9e25168abbf7e969b54b (patch)
treefbd215080bb8f241fead7db2d4524f923d146b07 /crypto/dso/dso_dl.c
parent34b537ee66eb7d327ff04121ccb7b9cc6b07ab3e (diff)
Add DSO_global_lookup_func implementation. See commentary in dso_lib.c
for further details.
Diffstat (limited to 'crypto/dso/dso_dl.c')
-rw-r--r--crypto/dso/dso_dl.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/crypto/dso/dso_dl.c b/crypto/dso/dso_dl.c
index dccb8e7ee8..7c123c8580 100644
--- a/crypto/dso/dso_dl.c
+++ b/crypto/dso/dso_dl.c
@@ -86,6 +86,7 @@ static int dl_ctrl(DSO *dso, int cmd, long larg, void *parg);
static char *dl_name_converter(DSO *dso, const char *filename);
static char *dl_merger(DSO *dso, const char *filespec1, const char *filespec2);
static int dl_pathbyaddr(void *addr,char *path,int sz);
+static DSO_FUNC_TYPE dl_globallookup(const char *name);
static DSO_METHOD dso_meth_dl = {
"OpenSSL 'dl' shared library method",
@@ -103,7 +104,8 @@ static DSO_METHOD dso_meth_dl = {
dl_merger,
NULL, /* init */
NULL, /* finish */
- dl_pathbyaddr
+ dl_pathbyaddr,
+ dl_globallookup
};
DSO_METHOD *DSO_METHOD_dl(void)
@@ -380,4 +382,12 @@ static int dl_pathbyaddr(void *addr,char *path,int sz)
return -1;
}
+
+static DSO_FUNC_TYPE dl_globallookup(const char *name)
+ {
+ DSO_FUNC_TYPE ret;
+ shl_t h = NULL;
+
+ return shl_findsym(&h,name,TYPE_UNDEFINED,&ret) ? NULL : ret;
+ }
#endif /* DSO_DL */