You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2020/08/27 21:22:43 UTC
[commons-crypto] 03/04: More debug loging.
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-crypto.git
commit fddc51e7357290a262c3f0d5c2acce881cb46e4e
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Thu Aug 27 17:13:16 2020 -0400
More debug loging.
---
src/main/java/org/apache/commons/crypto/NativeCodeLoader.java | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/main/java/org/apache/commons/crypto/NativeCodeLoader.java b/src/main/java/org/apache/commons/crypto/NativeCodeLoader.java
index 2844124..01da07d 100644
--- a/src/main/java/org/apache/commons/crypto/NativeCodeLoader.java
+++ b/src/main/java/org/apache/commons/crypto/NativeCodeLoader.java
@@ -113,6 +113,9 @@ final class NativeCodeLoader {
// TODO Find a better way to do this later.
if (isDebug()) {
System.out.println(String.format(format, args));
+ if (args != null && args.length > 0 && args[0] instanceof Throwable) {
+ ((Throwable) args[0]).printStackTrace(System.out);
+ }
}
}
@@ -178,6 +181,7 @@ final class NativeCodeLoader {
}
return extractedLibFile;
} catch (final IOException e) {
+ debug("Ignoring %s", e);
return null;
}
}