Index: src/core/SkMallocPixelRef.cpp |
diff --git a/src/core/SkMallocPixelRef.cpp b/src/core/SkMallocPixelRef.cpp |
index f4ba969662589131351aa7efa6141a1f9b53267b..e0d937ec113e5bde15b9a0456b31edf2a9039513 100644 |
--- a/src/core/SkMallocPixelRef.cpp |
+++ b/src/core/SkMallocPixelRef.cpp |
@@ -56,8 +56,8 @@ SkMallocPixelRef* SkMallocPixelRef::NewAllocate(const SkImageInfo& info, |
return NULL; |
} |
- int32_t minRB = SkToS32(info.minRowBytes()); |
- if (minRB < 0) { |
+ int64_t minRB = info.minRowBytes64(); |
caryclark
2015/01/23 15:10:09
signature returns uint64_t
reed1
2015/01/23 15:35:39
trying a cast instead, to stay consistent with the
|
+ if (!sk_64_isS32(minRB)) { |
caryclark
2015/01/23 15:10:10
... then this would need to be sk_64_asS32(uint64_
|
return NULL; // allocation will be too large |
} |
if (requestedRowBytes > 0 && (int32_t)requestedRowBytes < minRB) { |