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

incorrect usage of Get/ReleasePrimitiveArrayCritical in WFontMetrics.bytesWidth

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.2
    • 1.4.2
    • client-libs
    • None
    • mantis
    • generic
    • windows_nt



      Name: osR10079 Date: 10/03/2002

      documentation of Get/ReleasePrimitiveArrayCritical() says
      that no JNI-calls are allowed between get and release. But in
      WFontMetrics.bytesWidth (awt_Font.cpp) we have the following code:

              pStrBody = (char *)env->GetPrimitiveArrayCritical(str, 0);

              jintArray array = (jintArray)env->GetObjectField(self,
                                                               AwtFont::widthsID);
              env->ReleasePrimitiveArrayCritical(array, widths, 0);
      This usage is wrong and should be corrected.
      ======================================================================

            son Oleg Sukhodolsky (Inactive)
            son Oleg Sukhodolsky (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: