summaryrefslogtreecommitdiff
path: root/security/gnupg/patches
diff options
context:
space:
mode:
authorchris <chris>2002-09-30 22:41:30 +0000
committerchris <chris>2002-09-30 22:41:30 +0000
commita97cee7a4200b1b415be5f12d2a2278bf86adb81 (patch)
tree6d3993368b68bf031e62f9989bba358f0342de06 /security/gnupg/patches
parent22ad18dd248775c873d5876e875f2a7c45f1ffac (diff)
downloadpkgsrc-a97cee7a4200b1b415be5f12d2a2278bf86adb81.tar.gz
fixup dlsym error checks. An error is indicated by dlsym returning NULL not
dlerror returning something valid.
Diffstat (limited to 'security/gnupg/patches')
-rw-r--r--security/gnupg/patches/patch-af22
1 files changed, 22 insertions, 0 deletions
diff --git a/security/gnupg/patches/patch-af b/security/gnupg/patches/patch-af
new file mode 100644
index 00000000000..c3653f509fa
--- /dev/null
+++ b/security/gnupg/patches/patch-af
@@ -0,0 +1,22 @@
+$NetBSD: patch-af,v 1.1 2002/09/30 22:41:31 chris Exp $
+
+--- cipher/dynload.c.orig Mon Sep 30 23:34:34 2002
++++ cipher/dynload.c Mon Sep 30 23:35:18 2002
+@@ -287,7 +287,7 @@
+ goto failure;
+ }
+ name = (char**)dlsym(el->handle, SYMBOL_VERSION);
+- if( (err=dlerror()) ) {
++ if( (name == NULL) && (err=dlerror()) ) {
+ log_error("%s: not a gnupg extension: %s\n", el->name, err );
+ goto failure;
+ }
+@@ -332,7 +332,7 @@
+
+ #ifdef HAVE_DL_DLOPEN
+ sym = dlsym(el->handle, SYMBOL_ENUM);
+- if( (err=dlerror()) ) {
++ if( (sym == NULL) && (err=dlerror()) ) {
+ log_error("%s: invalid gnupg extension: %s\n", el->name, err );
+ goto failure;
+ }