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

Issue 831583004: Adding check on input count (Closed)

Created:
5 years, 11 months ago by sugoi1
Modified:
5 years, 11 months ago
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

Adding check on input count An integer overflow is causing a memory allocation to succeed while it should fail for being too large. BUG=445810 Committed: https://skia.googlesource.com/skia/+/23d432080cb8506bf8e371b1637ce8f2de9c0c05

Patch Set 1 #

Total comments: 1

Patch Set 2 : Added overflow detection in SkAutoSTArray::reset #

Unified diffs Side-by-side diffs Delta from patch set Stats (+7 lines, -1 line) Patch
M include/core/SkTemplates.h View 1 2 chunks +7 lines, -1 line 0 comments Download

Messages

Total messages: 11 (4 generated)
sugoi1
5 years, 11 months ago (2015-01-07 19:08:26 UTC) #2
reed1
Hmm, I think we should just crash, since the requested size is just to big. ...
5 years, 11 months ago (2015-01-07 19:24:57 UTC) #4
Stephen White
https://codereview.chromium.org/831583004/diff/1/src/core/SkImageFilter.cpp File src/core/SkImageFilter.cpp (right): https://codereview.chromium.org/831583004/diff/1/src/core/SkImageFilter.cpp#newcode66 src/core/SkImageFilter.cpp:66: static const size_t maxInputs = ((size_t)(-1)) / sizeof(SkImageFilter*); Division ...
5 years, 11 months ago (2015-01-07 19:31:12 UTC) #6
sugoi1
Implemented reed@'s proposition
5 years, 11 months ago (2015-01-07 20:37:31 UTC) #7
reed1
lgtm later we may consider more sweeping ways to catch all malloc callers, but this ...
5 years, 11 months ago (2015-01-07 21:17:46 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/831583004/20001
5 years, 11 months ago (2015-01-07 21:18:24 UTC) #10
commit-bot: I haz the power
5 years, 11 months ago (2015-01-07 21:28:11 UTC) #11
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as
https://skia.googlesource.com/skia/+/23d432080cb8506bf8e371b1637ce8f2de9c0c05

Powered by Google App Engine
This is Rietveld 408576698