diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/core/SkScalerContext.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/core/SkScalerContext.cpp b/src/core/SkScalerContext.cpp index a7e2432cc1..1f71bf0885 100644 --- a/src/core/SkScalerContext.cpp +++ b/src/core/SkScalerContext.cpp @@ -113,10 +113,11 @@ SkScalerContext::SkScalerContext(SkTypeface* typeface, const SkDescriptor* desc) #ifdef SK_BUILD_FOR_ANDROID uint32_t len; const void* data = desc->findEntry(kAndroidOpts_SkDescriptorTag, &len); - SkASSERT(data); - SkOrderedReadBuffer buffer(data, len); - fPaintOptionsAndroid.unflatten(buffer); - SkASSERT(buffer.offset() == buffer.size()); + if (data) { + SkOrderedReadBuffer buffer(data, len); + fPaintOptionsAndroid.unflatten(buffer); + SkASSERT(buffer.offset() == buffer.size()); + } #endif } |