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

vmTestbase/nsk/jvmti/ test should be fixed to fail early if JVMTI function return error

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 15
    • Fix Version/s: 16
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b06

      Description

      The following example cause crash instead of failures
      err = jvmti->GetFrameLocation(thr, 0, &mid, &loc);
          if (err != JVMTI_ERROR_NONE) {
              printf("(GetFrameLocation) unexpected error: %s (%d)\n",
                     TranslateError(err), err);
              result = STATUS_FAILED;
          }

      The "mid" and "loc" shouldn't be used if GetFrameLocation failed.
      Immediate return from the function is needed if it failed with non-JVMTI_ERROR_NONE.

        Attachments

          Activity

            People

            Assignee:
            lmesnik Leonid Mesnik
            Reporter:
            lmesnik Leonid Mesnik
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: