OpenJDK / jdk / jdk
changeset 23728:0db9dcaf1036
6815126: intermittent SimulResumerTest.java failure
Reviewed-by: jbachorik, sla
author | sjiang |
---|---|
date | Tue, 08 Apr 2014 17:36:13 +0200 |
parents | c7c05d5eb440 |
children | c35edcf0144e |
files | jdk/test/com/sun/jdi/SimulResumerTest.java |
diffstat | 1 files changed, 11 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/jdk/test/com/sun/jdi/SimulResumerTest.java Tue Apr 08 11:25:56 2014 +0100 +++ b/jdk/test/com/sun/jdi/SimulResumerTest.java Tue Apr 08 17:36:13 2014 +0200 @@ -177,12 +177,18 @@ List<StackFrame> frames = thr.frames(); // no failure return value here; could cause an NPE + kind = "frames(0, size - 1)"; + System.out.println("kind = " + kind); int nframes = frames.size(); - if (nframes > 0) { - // hmm, how could it ever be 0? - kind = "frames(0, size - 1)"; - System.out.println("kind = " + kind); - thr.frames(0, frames.size() - 1); + while (nframes > 0) { + try { + thr.frames(0, nframes - 1); + break; + } catch (IndexOutOfBoundsException iobe) { + // 6815126. let's try to get less frames + iobe.printStackTrace(); + nframes--; + } } kind = "frameCount()";