Index: Source/web/tests/TouchActionTest.cpp |
diff --git a/Source/web/tests/TouchActionTest.cpp b/Source/web/tests/TouchActionTest.cpp |
index f5d1c4f26d8f82dd13076aaf73805219b925f6ac..9545d167c99bbeaddf9339f848dad43cf00d7ec6 100644 |
--- a/Source/web/tests/TouchActionTest.cpp |
+++ b/Source/web/tests/TouchActionTest.cpp |
@@ -147,7 +147,7 @@ void TouchActionTest::runShadowDOMTest(std::string file) |
WebCore::TrackExceptionState es; |
RefPtrWillBeRawPtr<WebCore::Document> document = static_cast<PassRefPtrWillBeRawPtr<WebCore::Document> >(webView->mainFrame()->document()); |
- RefPtr<WebCore::NodeList> hostNodes = document->querySelectorAll("[shadow-host]", es); |
+ RefPtrWillBeRawPtr<WebCore::NodeList> hostNodes = document->querySelectorAll("[shadow-host]", es); |
ASSERT_FALSE(es.hadException()); |
ASSERT_GE(hostNodes->length(), 1u); |
@@ -186,10 +186,16 @@ void TouchActionTest::runTestOnTree(WebCore::ContainerNode* root, WebView* webVi |
{ |
// Find all elements to test the touch-action of in the document. |
WebCore::TrackExceptionState es; |
- RefPtr<WebCore::NodeList> nodes = root->querySelectorAll("[expected-action]", es); |
+ RefPtrWillBeRawPtr<WebCore::NodeList> nodes = root->querySelectorAll("[expected-action]", es); |
ASSERT_FALSE(es.hadException()); |
for (unsigned index = 0; index < nodes->length(); index++) { |
+ // FIXME: Oilpan: this is a longer running test that allocates. If the |
+ // PendingGCRunner task is run, it GCs assuming no pointers on the stack. |
+ // But there are here; explicitly GCing each time around this loop isn't |
+ // addressing that problem completely. |
+ WebCore::Heap::collectGarbage(WebCore::ThreadState::HeapPointersOnStack); |
+ |
WebCore::Element* element = toElement(nodes->item(index)); |
element->scrollIntoViewIfNeeded(); |
ASSERT_TRUE(nodes->item(index)->isElementNode()); |