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

Unified Diff: cc/ipc/cc_param_traits.cc

Issue 2835203002: Reject CompositorFrames with no render passes when deserializing (Closed)
Patch Set: Fixed Android Webview Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | cc/ipc/compositor_frame_struct_traits.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/ipc/cc_param_traits.cc
diff --git a/cc/ipc/cc_param_traits.cc b/cc/ipc/cc_param_traits.cc
index 3b04eb68511f0b7c9ec741c95374e0d446d82afa..2f6c5c222ce56c0f9bb93a9027bdb7ab479b3a53 100644
--- a/cc/ipc/cc_param_traits.cc
+++ b/cc/ipc/cc_param_traits.cc
@@ -795,7 +795,7 @@ bool ParamTraits<cc::CompositorFrame>::Read(const base::Pickle* m,
uint32_t num_render_passes;
if (!ReadParam(m, iter, &p->resource_list) ||
- !ReadParam(m, iter, &num_render_passes) ||
+ !ReadParam(m, iter, &num_render_passes) || num_render_passes == 0 ||
num_render_passes > kMaxRenderPasses)
return false;
for (uint32_t i = 0; i < num_render_passes; ++i) {
« no previous file with comments | « no previous file | cc/ipc/compositor_frame_struct_traits.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698