From: chibash Date: Thu, 26 Oct 2017 21:51:38 +0000 (+0900) Subject: changes ClassPool#appendSystemPath(). The new implementation appends ClassClassPath... X-Git-Tag: rel_3_23_0_ga~14 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fheads%2F3.22-old-style-source;p=javassist.git changes ClassPool#appendSystemPath(). The new implementation appends ClassClassPath when the JVM is earlier than 9. --- diff --git a/javassist.jar b/javassist.jar index 7d27f307..915b45a6 100644 Binary files a/javassist.jar and b/javassist.jar differ diff --git a/src/main/javassist/ClassPoolTail.java b/src/main/javassist/ClassPoolTail.java index 681c550e..1b580855 100644 --- a/src/main/javassist/ClassPoolTail.java +++ b/src/main/javassist/ClassPoolTail.java @@ -240,8 +240,12 @@ final class ClassPoolTail { } public ClassPath appendSystemPath() { - ClassLoader cl = Thread.currentThread().getContextClassLoader(); - return appendClassPath(new LoaderClassPath(cl)); + if (javassist.bytecode.ClassFile.MAJOR_VERSION < javassist.bytecode.ClassFile.JAVA_9) + return appendClassPath(new ClassClassPath()); + else { + ClassLoader cl = Thread.currentThread().getContextClassLoader(); + return appendClassPath(new LoaderClassPath(cl)); + } } public ClassPath insertClassPath(String pathname)