summaryrefslogtreecommitdiffstats
path: root/skia/ext/bitmap_platform_device_win.cc
diff options
context:
space:
mode:
Diffstat (limited to 'skia/ext/bitmap_platform_device_win.cc')
-rw-r--r--skia/ext/bitmap_platform_device_win.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/skia/ext/bitmap_platform_device_win.cc b/skia/ext/bitmap_platform_device_win.cc
index ab9db32..a52dd4e 100644
--- a/skia/ext/bitmap_platform_device_win.cc
+++ b/skia/ext/bitmap_platform_device_win.cc
@@ -152,7 +152,7 @@ BitmapPlatformDevice* BitmapPlatformDevice::CreateAndClear(int width,
bool is_opaque) {
BitmapPlatformDevice* device = BitmapPlatformDevice::Create(width, height,
is_opaque);
- if (!is_opaque)
+ if (device && !is_opaque)
device->accessBitmap(true).eraseARGB(0, 0, 0, 0);
return device;
}