Commit d567e23e authored by pwestin@google.com's avatar pwestin@google.com

Fix memory leak in tests.

Fixes 2 memory leaks related to GPU accelerated video encoding.
The TaskRunner must run one final time to clean the memory.

BUG=333142

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

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@244422 0039d316-1c4b-4281-b951-d872f2087c98
parent e561484d
......@@ -130,6 +130,9 @@ TEST_F(ExternalVideoEncoderTest, EncodePattern30fpsRunningOutOfAck) {
frame_encoded_callback));
task_runner_->RunTasks();
}
// We need to run the task to cleanup the GPU instance.
video_encoder_.reset(NULL);
task_runner_->RunTasks();
}
} // namespace cast
......
......@@ -129,6 +129,10 @@ TEST_F(VideoSenderTest, ExternalEncoder) {
video_sender_->InsertRawVideoFrame(video_frame, capture_time);
task_runner_->RunTasks();
// We need to run the task to cleanup the GPU instance.
video_sender_.reset(NULL);
task_runner_->RunTasks();
}
TEST_F(VideoSenderTest, RtcpTimer) {
......
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