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

JDWP: WatchpointEvents outside of class filtered out

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2 P2
    • 1.3.1
    • 1.3.0
    • core-svc
    • ladybird
    • generic
    • generic
    • Not verified

        michelle.devereux@Ireland 2001-01-26
        As reported by the customer:

        The current implementation of the JPDA does not produce ModificationWatchpointEvents when a field is modified by a class which
        is not the same class (or a sub-class) as the one that defined the field.

        However, the JPDA specification appears to say that any modifications to
        the watched field (inside the JVM/JNI) should be reported as
        ModificationWatchpointEvents.

        The problem seems to be in the "selectorFilter" function of
        "EventHandler.c"...

        The current restrictive test is:

                    case JDWP_REQUEST_MODIFIER(FieldOnly):
                        /*
                         * Field watchpoints can be triggered from the declared
        class
                         * or any subclass/subinterface.
                         */
                        if ((event->u.field_access.field !=
                                 select->u.FieldOnly.field) ||
                            !(*env)->IsAssignableFrom(env, clazz,
                                                 select->u.FieldOnly.clazz)) {
                            return JNI_FALSE;
                        }

        ----

        The class being compared is the location of the event instead
        of the class of the field.

              tbell Tim Bell
              mdevereuorcl Michelle Devereux (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: