Skip to content

Commit

Permalink
fall back to system class loader (#774)
Browse files Browse the repository at this point in the history
  • Loading branch information
graebm authored Mar 25, 2024
1 parent b04445e commit daafa7c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/java/software/amazon/awssdk/crt/CRT.java
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,10 @@ public boolean accept(File dir, String name) {

private static CrtPlatform findPlatformImpl() {
ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
if (classLoader == null) {
classLoader = ClassLoader.getSystemClassLoader();
}

String[] platforms = new String[] {
// Search for OS specific test impl first
String.format("software.amazon.awssdk.crt.test.%s.CrtPlatformImpl", getOSIdentifier()),
Expand Down

0 comments on commit daafa7c

Please sign in to comment.