Catch AccessControlException in Secp256k1Context initialization

This commit is contained in:
ScripterRon
2016-09-03 16:12:11 -04:00
committed by Andreas Schildbach
parent 7d48f7927f
commit 135d3c7f16

View File

@@ -19,6 +19,8 @@ package org.bitcoin;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.security.AccessControlException;
/**
* This class holds the context reference used in native methods to handle ECDSA operations.
*/
@@ -38,6 +40,9 @@ public class Secp256k1Context {
} catch (UnsatisfiedLinkError e) {
log.info(e.toString());
isEnabled = false;
} catch (AccessControlException e) {
log.debug(e.toString());
isEnabled = false;
}
enabled = isEnabled;
context = contextRef;