From 5e878024aa2772f111f944fff519a6cce6f4cb8a Mon Sep 17 00:00:00 2001 From: rcritten Date: Wed, 13 Jan 2010 21:21:04 +0000 Subject: [PATCH] Need to explicitly catch UnsatisfiedLinkError exception for System.load() --- jss-loadlibrary.patch | 4 ++-- jss.spec | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/jss-loadlibrary.patch b/jss-loadlibrary.patch index ac841b1..a8643a4 100644 --- a/jss-loadlibrary.patch +++ b/jss-loadlibrary.patch @@ -15,12 +15,12 @@ diff -uN --recursive jss-4.2.6.orig/mozilla/security/jss/org/mozilla/jss/CryptoM + System.load( "/usr/lib64/jss/libjss4.so" ); + Debug.trace(Debug.VERBOSE, "jss library loaded"); + mNativeLibrariesLoaded = true; -+ } catch( Exception e ) { ++ } catch( UnsatisfiedLinkError e ) { + try { + System.load( "/usr/lib/jss/libjss4.so" ); + Debug.trace(Debug.VERBOSE, "jss library loaded"); + mNativeLibrariesLoaded = true; -+ } catch( Exception f ) { ++ } catch( UnsatisfiedLinkError f ) { + Debug.trace(Debug.VERBOSE, "jss library load failed"); + } + } diff --git a/jss.spec b/jss.spec index bd4664f..3c54bd0 100644 --- a/jss.spec +++ b/jss.spec @@ -1,6 +1,6 @@ Name: jss Version: 4.2.6 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Java Security Services (JSS) Group: System Environment/Libraries @@ -143,6 +143,9 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Wed Jan 13 2010 Rob Crittenden 4.2.6-6 +- Need to explicitly catch UnsatisfiedLinkError exception for System.load() + * Thu Jan 7 2010 Rob Crittenden 4.2.6-5 - Move location of libjss4.so to subdirectory and use System.load() to load it instead of System.loadLibrary() for Fedora packaging compliance