Workaround for a JDK crash triggered by StackWalker
when classes have been redefined:
https://bugs.openjdk.java.net/browse/JDK-8210457
https://bugs.openjdk.java.net/browse/JDK-8221437
(ClassGraph bug #341)
This could be triggered as easily as by adding Hamcrest to a project, since Hamcrest appears to redefine classes.
This JDK bug affects JDK 9, 10, 11.0.0-11.0.3 inclusive, and 12.0.0-12.0.1 inclusive. It was fixed in JDK 13-ea, and backported to JDK 11.0.4 and 12.0.2.
For affected JDK versions, ClassGraph uses an older fallback mechanism to get the call stack, and disables StackWalker
code.