Commit d9d5b48c authored by haraken's avatar haraken Committed by Commit bot

Fix memory leakage in VideoSourceHandlerTest.OpenWithoutClose

This CL is needed for landing https://codereview.chromium.org/552653005.
https://codereview.chromium.org/552653005 moves MediaStream-related objects
to Oilpan's heap, and the objects are not collected until a next GC is triggered.
Thus some of the Chromium-side tests need to clear those objects and explicitly
trigger a GC in order to make sure that all objects are collected by the end of
each test. Otherwise LSan complains the leakage.

I've already landed a similar fix before: https://codereview.chromium.org/566793002/

I think this CL is a final fix for the memory leakage.

BUG=416466

Review URL: https://codereview.chromium.org/596923003

Cr-Commit-Position: refs/heads/master@{#297145}
parent 8b0ae1bd
......@@ -53,6 +53,7 @@ class VideoSourceHandlerTest : public ::testing::Test {
virtual void TearDown() {
registry_.reset();
handler_.reset();
blink::WebHeap::collectAllGarbageForTesting();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment