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

JNI DetachCurrentThread decrements the UserThreadCount under green threads

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P2 P2
    • None
    • 1.2.0
    • hotspot
    • None
    • generic
    • generic

      JNI DetachCurrentThread decrements the UserThreadCount while
      JNI AttachCurrentThread doesn't - under green threads. On
      native & win32 AttachCurrentThread increments UserThreadCount.

      One effect of this is that java_main.c which does the following JNI
      calls in sequence: DetachCurrentThread, AttachCurrentThread, DestroyJavaVM -
      exits prematurely because the UserThreadCount is incorrectly one. This, at
      a minimum, causes the debugger to exit prematurely.

            never Tom Rodriguez
            rfield Robert Field (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: