Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4755350

Debugger skips multiple lines / continues execution at the same time

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P4 P4
    • tbd
    • 1.4.0_02
    • core-svc
    • None
    • x86
    • linux

      Debugger skips multiple lines/ continues execution at the same time. This bug affects j2sdk1.4.0, j2sdk1.4.0_01, j2sdk1.4.0_02. The latest JDKs (j2sdk1.4.1-build21, j2sdk1.4.2-build02) don't contain this bug. Here is a test case:
      - start jdb ($JAVA_HOME/bin/jdb)
      - put a breakpoint to the line 8 (stop at Test:8)
      - run a java test file (run Test)
      - step to the next line (next)
      - step to the next line again; line 10 is expected (next)
      ! The line 10 is expected, but the debugger continues until a breakpoint is hit !


      public class Test {
          public static void main( String args[] ) throws Exception {
              test1();
          }

          public static void test1() {
              for( int i = 0; i < 10; i++ ) {
                  System.out.println( "aaa" );
                  test2();
                  System.out.println( "ddd" );
              }
          }

          public static void test2() {
              try {
                  System.out.println( "bbb" );
                  throw new Exception( "test" );
              } catch( Exception e ) {
                  System.out.println( "ccc" );
              }
          }
      }

            jjh James Holmlund (Inactive)
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: