Index: src/objects-debug.cc |
diff --git a/src/objects-debug.cc b/src/objects-debug.cc |
index c31a79d08fe87c813f46ad7bd425e3cafc8e9088..4e7cf8f1dfb20faf28f30c3d9e861cf57fe773ba 100644 |
--- a/src/objects-debug.cc |
+++ b/src/objects-debug.cc |
@@ -1270,7 +1270,10 @@ void Code::VerifyEmbeddedObjects(VerifyMode mode) { |
RelocInfo::ModeMask(RelocInfo::CELL); |
bool skip_weak_cell = (mode == kNoContextSpecificPointers) ? false : true; |
for (RelocIterator it(this, mask); !it.done(); it.next()) { |
- CHECK(!CanLeak(it.rinfo()->target_object(), heap, skip_weak_cell)); |
+ Object* target = it.rinfo()->rmode() == RelocInfo::CELL |
+ ? it.rinfo()->target_cell() |
+ : it.rinfo()->target_object(); |
+ CHECK(!CanLeak(target, heap, skip_weak_cell)); |
} |
} |