diff options
author | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-12-30 14:24:37 +0000 |
---|---|---|
committer | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2013-12-30 14:24:37 +0000 |
commit | 4ad4ae907fa83773f671137b0e4e8c9525ab81cd (patch) | |
tree | a3b424ce1bfe5f345ca68ff2f22c285866b6e36f /src/core/SkMallocPixelRef.cpp | |
parent | a306d93cd73c3fc1d81479cbba98638f1e055385 (diff) |
Reason for revert: need to update callsites in linux codecs
R=robertphillips@google.com
TBR=robertphillips@google.com
NOTREECHECKS=true
NOTRY=true
BUG=
Author: reed@google.com
Review URL: https://codereview.chromium.org/122283002
git-svn-id: http://skia.googlecode.com/svn/trunk@12841 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/core/SkMallocPixelRef.cpp')
-rw-r--r-- | src/core/SkMallocPixelRef.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/SkMallocPixelRef.cpp b/src/core/SkMallocPixelRef.cpp index 9e2ea9c980..b65197fac8 100644 --- a/src/core/SkMallocPixelRef.cpp +++ b/src/core/SkMallocPixelRef.cpp @@ -64,12 +64,13 @@ SkMallocPixelRef* SkMallocPixelRef::NewAllocate(const SkImageInfo& info, rowBytes = minRB; } - int64_t bigSize = (int64_t)info.fHeight * rowBytes; - if (!sk_64_isS32(bigSize)) { + Sk64 bigSize; + bigSize.setMul(info.fHeight, rowBytes); + if (!bigSize.is32()) { return NULL; } - size_t size = sk_64_asS32(bigSize); + size_t size = bigSize.get32(); void* addr = sk_malloc_flags(size, 0); if (NULL == addr) { return NULL; |