提交 7c5da9b3 编写于 作者: V Vojtech Juranek

Remove potential infinite loop (related to JENKINS-5922) + formating of previous patch

上级 f28409ee
......@@ -114,14 +114,14 @@ public class Which {
try {
Object delegate = is;
while (delegate.getClass().getEnclosingClass()!=ZipFile.class) {
Field f = is.getClass().getDeclaredField("delegate");
Field f = delegate.getClass().getDeclaredField("delegate");
f.setAccessible(true);
delegate = f.get(is);
//JENKINS-5922 - workaround for CertificateReaderInputStream; JBoss 5.0.0, EAP 5.0 and EAP 5.1
delegate = f.get(delegate);
//JENKINS-5922 - workaround for CertificateReaderInputStream; JBoss 5.0.0, EAP 5.0 and EAP 5.1
if(delegate.getClass().getName().equals("java.util.jar.JarVerifier$VerifierStream")){
f = delegate.getClass().getDeclaredField("is");
f.setAccessible(true);
delegate = f.get(delegate);
f = delegate.getClass().getDeclaredField("is");
f.setAccessible(true);
delegate = f.get(delegate);
}
}
Field f = delegate.getClass().getDeclaredField("this$0");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册