changeset 155:e1bf7407c933

6469580: 1.5.0_08 JVM crashes in SignatureHandlerLibrary::add on Fujitsu Primepower platform Reviewed-by: andreas, valeriep, wetmore Contributed-by: chris.phillips@sun.com
author wetmore
date Mon, 31 Mar 2008 13:27:10 -0700
parents 8805ae9d160c
children 99b3301fc27c
files src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c	Mon Mar 31 11:09:57 2008 -0700
+++ b/src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c	Mon Mar 31 13:27:10 2008 -0700
@@ -123,7 +123,10 @@
         C_GetFunctionList = (CK_C_GetFunctionList) dlsym(hModule, getFunctionListStr);
         (*env)->ReleaseStringUTFChars(env, jGetFunctionList, getFunctionListStr);
     }
-    if ((C_GetFunctionList == NULL) || ((systemErrorMessage = dlerror()) != NULL)){
+    if (C_GetFunctionList == NULL) {
+        throwIOException(env, "ERROR: C_GetFunctionList == NULL");
+        return;
+    } else if ( (systemErrorMessage = dlerror()) != NULL ){
         throwIOException(env, systemErrorMessage);
         return;
     }