Index: third_party/WebKit/LayoutTests/storage/indexeddb/key-cursor-request-cycle.html |
diff --git a/third_party/WebKit/LayoutTests/storage/indexeddb/key-cursor-request-cycle.html b/third_party/WebKit/LayoutTests/storage/indexeddb/key-cursor-request-cycle.html |
index 4b24ace259f4399614251f4389b773d6bbf62bfc..a0e99fa3d6e2cccd4010929da562e58807d4994b 100644 |
--- a/third_party/WebKit/LayoutTests/storage/indexeddb/key-cursor-request-cycle.html |
+++ b/third_party/WebKit/LayoutTests/storage/indexeddb/key-cursor-request-cycle.html |
@@ -70,7 +70,10 @@ function onOpen(evt) |
preamble(evt); |
shouldBeEqualToString("cursor.key", "key2"); |
- cursorObservation = internals.observeGC(cursor); |
+ // Access objects in an inner function to avoid references to |
+ // objects remaining live on this function's stack frame |
+ // (http://crbug.com/595672/). |
+ (() => { cursorObservation = internals.observeGC(cursor); })(); |
evalAndLog("cursor = null"); |
evalAndLog("gc()"); |
shouldBeTrue("cursorRequestObservation.wasCollected"); |