Commit ae42f270 authored by mikhail.pozdnyakov's avatar mikhail.pozdnyakov Committed by Commit bot

Fix in LayoutTestPermissionManager::RequestPermissions

Resulting vector of statuses must have the same size as the given permissions vector.

Review-Url: https://codereview.chromium.org/2838543003
Cr-Commit-Position: refs/heads/master@{#467263}
parent 1d9e0b92
......@@ -88,7 +88,8 @@ int LayoutTestPermissionManager::RequestPermissions(
void(const std::vector<blink::mojom::PermissionStatus>&)>& callback) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
std::vector<blink::mojom::PermissionStatus> result(permissions.size());
std::vector<blink::mojom::PermissionStatus> result;
result.reserve(permissions.size());
const GURL& embedding_origin =
WebContents::FromRenderFrameHost(render_frame_host)
->GetLastCommittedURL().GetOrigin();
......
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