Commit c49bec08 authored by hclam@chromium.org's avatar hclam@chromium.org

Cast: Fix use after free in a testing tool

cast_simulator should call .Pass() to pass the PacketPipe for
simulation.

TBR=miu

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

Cr-Commit-Position: refs/heads/master@{#289226}
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289226 0039d316-1c4b-4281-b951-d872f2087c98
parent 3e54f396
...@@ -283,10 +283,12 @@ void RunSimulation(const base::FilePath& source_path, ...@@ -283,10 +283,12 @@ void RunSimulation(const base::FilePath& source_path,
// Connect sender to receiver. This initializes the pipe. // Connect sender to receiver. This initializes the pipe.
receiver_to_sender.Initialize( receiver_to_sender.Initialize(
ipp.NewBuffer(128 * 1024), transport_sender->PacketReceiverForTesting(), ipp.NewBuffer(128 * 1024).Pass(),
transport_sender->PacketReceiverForTesting(),
task_runner, &testing_clock); task_runner, &testing_clock);
sender_to_receiver.Initialize( sender_to_receiver.Initialize(
ipp.NewBuffer(128 * 1024), cast_receiver->packet_receiver(), task_runner, ipp.NewBuffer(128 * 1024).Pass(),
cast_receiver->packet_receiver(), task_runner,
&testing_clock); &testing_clock);
// Start receiver. // Start receiver.
......
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