src/hotspot/share/services/threadService.cpp
changeset 49658 8237a91c1cca
parent 49480 d7df2dd501ce
child 50065 ae0ebd3cf949
--- a/src/hotspot/share/services/threadService.cpp	Tue Apr 03 10:27:46 2018 +0200
+++ b/src/hotspot/share/services/threadService.cpp	Tue Apr 03 13:15:27 2018 +0200
@@ -607,7 +607,7 @@
     for (int j = 0; j < len; j++) {
       oop monitor = locked_monitors->at(j);
       assert(monitor != NULL, "must be a Java object");
-      if (monitor == object) {
+      if (oopDesc::equals(monitor, object)) {
         found = true;
         break;
       }