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

Issue 822953002: Validate Bucket data in ShaderSourceBucket. (Closed)

Created:
6 years ago by sivag
Modified:
5 years, 11 months ago
CC:
chromium-reviews, piman+watch_chromium.org, Thanik
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Validate Bucket data in ShaderSourceBucket. As of now only the received bucket and the size of bucket are validated. We should check for validation of bucket data before we start using it and report failures. BUG=240467 Committed: https://crrev.com/6df438ed2adaf24fa2f4a92d4f3863825247b910 Cr-Commit-Position: refs/heads/master@{#309882}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Patch Set 4 : #

Total comments: 2

Patch Set 5 : Added setSize error handling in command decoder. #

Patch Set 6 : Added braces to error check. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+10 lines, -3 lines) Patch
M gpu/command_buffer/service/common_decoder.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M gpu/command_buffer/service/common_decoder.cc View 1 2 3 4 5 2 chunks +9 lines, -2 lines 0 comments Download

Messages

Total messages: 18 (7 generated)
sivag
ptal..
5 years, 12 months ago (2014-12-24 13:31:12 UTC) #3
Zhenyao Mo
https://codereview.chromium.org/822953002/diff/60001/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/822953002/diff/60001/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode7094 gpu/command_buffer/service/gles2_cmd_decoder.cc:7094: if (!bucket->GetData(0, bucket->size() - 1)) { Good catch. But ...
5 years, 11 months ago (2014-12-31 00:13:47 UTC) #7
sivag
ptal.. https://codereview.chromium.org/822953002/diff/60001/gpu/command_buffer/service/gles2_cmd_decoder.cc File gpu/command_buffer/service/gles2_cmd_decoder.cc (right): https://codereview.chromium.org/822953002/diff/60001/gpu/command_buffer/service/gles2_cmd_decoder.cc#newcode7094 gpu/command_buffer/service/gles2_cmd_decoder.cc:7094: if (!bucket->GetData(0, bucket->size() - 1)) { On 2014/12/31 ...
5 years, 11 months ago (2014-12-31 11:22:20 UTC) #9
Zhenyao Mo
LGTM
5 years, 11 months ago (2015-01-02 18:15:50 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/822953002/100001
5 years, 11 months ago (2015-01-04 02:43:00 UTC) #12
commit-bot: I haz the power
Committed patchset #6 (id:100001)
5 years, 11 months ago (2015-01-04 03:37:32 UTC) #13
commit-bot: I haz the power
Patchset 6 (id:??) landed as https://crrev.com/6df438ed2adaf24fa2f4a92d4f3863825247b910 Cr-Commit-Position: refs/heads/master@{#309882}
5 years, 11 months ago (2015-01-04 03:38:23 UTC) #14
piman
On Tue, Dec 30, 2014 at 4:13 PM, <zmo@chromium.org> wrote: > > https://codereview.chromium.org/822953002/diff/60001/gpu/ > command_buffer/service/gles2_cmd_decoder.cc ...
5 years, 11 months ago (2015-01-05 18:42:08 UTC) #15
Zhenyao Mo
On 2015/01/05 18:42:08, piman (Very slow to review) wrote: > On Tue, Dec 30, 2014 ...
5 years, 11 months ago (2015-01-05 18:56:03 UTC) #16
sivag
A revert of this CL (patchset #6 id:100001) has been created in https://codereview.chromium.org/802323005/ by siva.gunturi@samsung.com. ...
5 years, 11 months ago (2015-01-06 11:09:59 UTC) #17
sivag
5 years, 11 months ago (2015-01-06 11:13:11 UTC) #18
Message was sent while issue was closed.
On 2015/01/05 18:56:03, Zhenyao Mo wrote:
> On 2015/01/05 18:42:08, piman (Very slow to review) wrote:
> > On Tue, Dec 30, 2014 at 4:13 PM, <mailto:zmo@chromium.org> wrote:
> > 
> > >
> > > https://codereview.chromium.org/822953002/diff/60001/gpu/
> > > command_buffer/service/gles2_cmd_decoder.cc
> > > File gpu/command_buffer/service/gles2_cmd_decoder.cc (right):
> > >
> > > https://codereview.chromium.org/822953002/diff/60001/gpu/
> > > command_buffer/service/gles2_cmd_decoder.cc#newcode7094
> > > gpu/command_buffer/service/gles2_cmd_decoder.cc:7094: if
> > > (!bucket->GetData(0, bucket->size() - 1)) {
> > > Good catch.  But instead of checking it here, it makes more sense to
> > > strengthen the CommonDecoder::Bucket::SetSize to handle mem allocation
> > > failure, i.e., when mem alloc fails, set size to 0.
> > >
> > 
> > Mmh, allocations "can't" fail. new never returns NULL. In Chrome we
> > explicitly abort (crash) before returning from the allocator in case of
> > allocation failure.
> 
> Ah, I didn't know that.  So nothing needs to be done here actually.
> 
> @sikugu, sorry for the incorrect information.  Could you revert your CL?
> 
> > 
> > 
> > >
> > > https://codereview.chromium.org/822953002/
> > >
> > 
> > To unsubscribe from this group and stop receiving emails from it, send an
> email
> > to mailto:chromium-reviews+unsubscribe@chromium.org.

Done.

Powered by Google App Engine
This is Rietveld 408576698