Assert firing due to large pointer values wrapping negative in signed int |
||
Issue descriptionsrc/image/SkImage_Gpu.cpp has SkAssert(mipLevelPtr > bufferAsInt); mipLevelPtr (as well as other pointers in that function) are saved as intptr_t so they can be used with SkAlign8. char* won't work with SkAlign8. Any other pointer type would additionally cause aliasing. But if the value of mipLevelPtr is large, when cast to an intptr_t it will wrap into the negatives. This causes the assert to fail, since it is now less than bufferAsInt. Change the intptr_t to uintptr_t
,
Sep 20 2016
,
Sep 20 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/8a2e1b67e9efc059cddf7a030b353b44311a19dd commit 8a2e1b67e9efc059cddf7a030b353b44311a19dd Author: skia-deps-roller <skia-deps-roller@chromium.org> Date: Tue Sep 20 05:07:42 2016 Roll src/third_party/skia/ 4562f6ecd..05a3eac35 (1 commit). https://chromium.googlesource.com/skia.git/+log/4562f6ecda4d..05a3eac35c58 $ git log 4562f6ecd..05a3eac35 --date=short --no-merges --format='%ad %ae %s' 2016-09-19 cblume SkASSERT firing because pointer wraps negative. BUG= 648452 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_precise_blink_rel TBR=borenet@google.com Review-Url: https://codereview.chromium.org/2354813002 Cr-Commit-Position: refs/heads/master@{#419683} [modify] https://crrev.com/8a2e1b67e9efc059cddf7a030b353b44311a19dd/DEPS |
||
►
Sign in to add a comment |
||
Comment 1 by bugdroid1@chromium.org
, Sep 20 2016