OSDN Git Service

Lock SkBitmap before accessing color table
authorLeon Scroggins III <scroggo@google.com>
Tue, 2 Feb 2016 16:11:55 +0000 (11:11 -0500)
committerLeon Scroggins <scroggo@google.com>
Tue, 2 Feb 2016 19:05:02 +0000 (19:05 +0000)
commit66ce1c3b1a7b5ed3d4d5a9a05a7c133998c9a73e
tree784bf702a8b3141c348ed407df8aff9da16a28b8
parentfe54b11803e7940d23b6c540b2e6db738299702c
Lock SkBitmap before accessing color table

This only affects kIndex_8 Bitmaps, which can only be created by
decoding particular images (e.g. GIF). Without locking the SkBitmap,
colorTable() always returns NULL. Lock it so we can write the color
table to the Parcel.

BUG:26527976
Change-Id: Ifc54b06ca08db26ba6455a3830b7e671b64f37c4
core/jni/android/graphics/Bitmap.cpp