diff options
author | Tom Yu <tlyu@mit.edu> | 2010-05-19 18:52:36 +0000 |
---|---|---|
committer | Tom Yu <tlyu@mit.edu> | 2010-05-19 18:52:36 +0000 |
commit | 83e30ba0f4d111a1b64b079ac7b8bb481c2e6b21 (patch) | |
tree | 74259f4feb64db0dd6034d2118d35d3b497d4692 | |
parent | 3401907d2433bb23762edfc453b6da965fcef18a (diff) | |
download | krb5-83e30ba0f4d111a1b64b079ac7b8bb481c2e6b21.zip krb5-83e30ba0f4d111a1b64b079ac7b8bb481c2e6b21.tar.gz krb5-83e30ba0f4d111a1b64b079ac7b8bb481c2e6b21.tar.bz2 |
pull up r23929 from trunk
------------------------------------------------------------------------
r23929 | tlyu | 2010-04-22 21:30:48 -0400 (Thu, 22 Apr 2010) | 7 lines
ticket: 6697
target_version: 1.8.2
tags: pullup
Adapted patch from Arlene Berry to handle dlerror() returning a null
pointer.
ticket: 6697
version_fixed: 1.8.2
status: resolved
git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-8@24058 dc483132-0cff-0310-8789-dd5450dbe970
-rw-r--r-- | src/util/support/plugins.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/util/support/plugins.c b/src/util/support/plugins.c index fa7b36e..4e92254 100644 --- a/src/util/support/plugins.c +++ b/src/util/support/plugins.c @@ -268,6 +268,8 @@ krb5int_open_plugin (const char *filepath, struct plugin_file_handle **h, struct handle = dlopen(filepath, PLUGIN_DLOPEN_FLAGS); if (handle == NULL) { const char *e = dlerror(); + if (e == NULL) + e = "unknown failure"; Tprintf ("dlopen(%s): %s\n", filepath, e); err = ENOENT; /* XXX */ krb5int_set_error (ep, err, "%s", e); @@ -335,6 +337,8 @@ krb5int_get_plugin_sym (struct plugin_file_handle *h, sym = dlsym (h->dlhandle, csymname); if (sym == NULL) { const char *e = dlerror (); /* XXX copy and save away */ + if (e == NULL) + e = "unknown failure"; Tprintf ("dlsym(%s): %s\n", csymname, e); err = ENOENT; /* XXX */ krb5int_set_error(ep, err, "%s", e); |