diff options
author | peter <peter@FreeBSD.org> | 1999-12-17 20:21:45 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1999-12-17 20:21:45 +0000 |
commit | 81c8f9fa6d4fdbc6426923c2f8fad809b478d297 (patch) | |
tree | 0dad56ee0f905476c2a7d81621b5c2197a08caca /lib | |
parent | 3da8bcb7dc4f039a7da3033a29d6f3b5f07487a7 (diff) | |
download | FreeBSD-src-81c8f9fa6d4fdbc6426923c2f8fad809b478d297.zip FreeBSD-src-81c8f9fa6d4fdbc6426923c2f8fad809b478d297.tar.gz |
Make a dlopen failure consistant with dlsym(). "Shouldn't happen."
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libcrypt/crypt-md5.c | 4 | ||||
-rw-r--r-- | lib/libcrypt/crypt-shs.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/lib/libcrypt/crypt-md5.c b/lib/libcrypt/crypt-md5.c index 004ba60..c112bd8 100644 --- a/lib/libcrypt/crypt-md5.c +++ b/lib/libcrypt/crypt-md5.c @@ -75,8 +75,10 @@ crypt_md5(pw, salt) #ifdef __PIC__ libmd = dlopen("libmd.so", RTLD_NOW); - if (libmd == NULL) + if (libmd == NULL) { + warnx("libcrypt-md5: dlopen(libmd.so): %s\n", dlerror()); return NULL; + } dl_MD5Init = dlsym(libmd, "MD5Init"); if (dl_MD5Init == NULL) { warnx("libcrypt-md5: looking for MD5Init: %s\n", dlerror()); diff --git a/lib/libcrypt/crypt-shs.c b/lib/libcrypt/crypt-shs.c index 4f69305..11a7aaf 100644 --- a/lib/libcrypt/crypt-shs.c +++ b/lib/libcrypt/crypt-shs.c @@ -75,8 +75,10 @@ crypt_sha(pw, salt) #ifdef __PIC__ libmd = dlopen("libmd.so", RTLD_NOW); - if (libmd == NULL) + if (libmd == NULL) { + warnx("libcrypt-md5: dlopen(libmd.so): %s\n", dlerror()); return NULL; + } dl_SHA_Init = dlsym(libmd, "SHA_Init"); if (dl_SHA_Init == NULL) { warnx("libcrypt-md5: looking for SHA_Init: %s\n", dlerror()); |