hotspot/agent/src/share/classes/sun/jvm/hotspot/jdi/ObjectReferenceImpl.java
changeset 3171 aa289b22b577
parent 1 489c9b5090e2
child 3261 c7d5aae8d3f7
--- a/hotspot/agent/src/share/classes/sun/jvm/hotspot/jdi/ObjectReferenceImpl.java	Fri Jun 05 10:25:39 2009 -0700
+++ b/hotspot/agent/src/share/classes/sun/jvm/hotspot/jdi/ObjectReferenceImpl.java	Tue Jun 09 16:19:10 2009 -0700
@@ -249,6 +249,7 @@
             OopHandle givenHandle = obj.getHandle();
             for (Iterator itr = monitors.iterator(); itr.hasNext();) {
                 MonitorInfo mi = (MonitorInfo) itr.next();
+                if (mi.eliminated() && frame.isCompiledFrame()) continue; // skip eliminated monitor
                 if (givenHandle.equals(mi.owner())) {
                     res++;
                 }