projects
/
platform
/
upstream
/
libSkiaSharp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5a3d92f
)
Fixed clusterfuzz issue
author
sugoi
<sugoi@chromium.org>
Wed, 28 Jan 2015 21:15:32 +0000
(13:15 -0800)
committer
Commit bot
<commit-bot@chromium.org>
Wed, 28 Jan 2015 21:15:32 +0000
(13:15 -0800)
BUG=448423
Review URL: https://codereview.chromium.org/
881423002
src/core/SkBitmap.cpp
patch
|
blob
|
history
diff --git
a/src/core/SkBitmap.cpp
b/src/core/SkBitmap.cpp
index c962aea21a10fc3dd4e31705a9c334dcf83e450d..e77bbbd4e5e461cd6bd1030584ab1efd824b0ea8 100644
(file)
--- a/
src/core/SkBitmap.cpp
+++ b/
src/core/SkBitmap.cpp
@@
-1232,6
+1232,9
@@
bool SkBitmap::ReadRawPixels(SkReadBuffer* buffer, SkBitmap* bitmap) {
SkAutoTUnref<SkPixelRef> pr(SkMallocPixelRef::NewWithData(info, info.minRowBytes(),
ctable.get(), data.get()));
+ if (!pr.get()) {
+ return false;
+ }
bitmap->setInfo(pr->info());
bitmap->setPixelRef(pr, 0, 0);
return true;