Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(687)

Issue 2835203002: Reject CompositorFrames with no render passes when deserializing (Closed)

Created:
3 years, 8 months ago by Saman Sami
Modified:
3 years, 8 months ago
Reviewers:
Tom Sepez, boliu
CC:
chromium-reviews, jam, cc-bugs_chromium.org, darin-cc_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Reject CompositorFrames with no render passes when deserializing LayerTreeHostImpl::DrawLayers never submits a CompositorFrame with no render passes. Currently we verify that the CompositorFrame sent from the renderer does not have an empty render pass list in RenderWidgetHostImpl::SubmitCompositorFrame. This check is necessary because letting such CompositorFrames through will violate assumptions and causes the browser to crash. This CL moves the validation code to StructTraits / ParamTraits to centralize IPC message validation. Some changes in Android's synchronous compositor was necessary because currently when it wants to send the CompositorFrameMetadata to the browser, instead of just sending the metadata directly it creates an empty CompositorFrame, puts the metadata there and then sends the frame. Such frames do not pass the new validation rule, so now we just send the metadata directly. CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel Review-Url: https://codereview.chromium.org/2835203002 Cr-Commit-Position: refs/heads/master@{#466708} Committed: https://chromium.googlesource.com/chromium/src/+/ac53e53db3b6db49588a3ad69ba4231308091009

Patch Set 1 #

Patch Set 2 : Fixed Android Webview #

Unified diffs Side-by-side diffs Delta from patch set Stats (+21 lines, -35 lines) Patch
M cc/ipc/cc_param_traits.cc View 1 chunk +1 line, -1 line 0 comments Download
M cc/ipc/compositor_frame_struct_traits.cc View 1 chunk +3 lines, -5 lines 0 comments Download
M content/browser/android/synchronous_compositor_host.cc View 1 2 chunks +8 lines, -12 lines 0 comments Download
M content/browser/renderer_host/render_widget_host_impl.cc View 1 1 chunk +0 lines, -6 lines 0 comments Download
M content/common/android/sync_compositor_messages.h View 1 1 chunk +2 lines, -3 lines 0 comments Download
M content/renderer/android/synchronous_compositor_proxy.h View 1 1 chunk +3 lines, -3 lines 0 comments Download
M content/renderer/android/synchronous_compositor_proxy.cc View 1 2 chunks +4 lines, -5 lines 0 comments Download

Messages

Total messages: 41 (35 generated)
Saman Sami
tsepez: Please review IPC.
3 years, 8 months ago (2017-04-24 18:28:17 UTC) #29
Tom Sepez
lgtm
3 years, 8 months ago (2017-04-24 18:35:41 UTC) #30
Saman Sami
boliu: Preview review changes to Android.
3 years, 8 months ago (2017-04-24 18:44:49 UTC) #33
boliu
lgtm
3 years, 8 months ago (2017-04-24 19:03:57 UTC) #34
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2835203002/120001
3 years, 8 months ago (2017-04-24 19:05:09 UTC) #37
commit-bot: I haz the power
3 years, 8 months ago (2017-04-24 19:12:47 UTC) #41
Message was sent while issue was closed.
Committed patchset #2 (id:120001) as
https://chromium.googlesource.com/chromium/src/+/ac53e53db3b6db49588a3ad69ba4...

Powered by Google App Engine
This is Rietveld 408576698