Snap for 4399706 from 467361dbcf to pi-release

Change-Id: Ibd977e2cf7a6628e298f3c02714f9fb8dcc171a7
This commit is contained in:
android-build-team Robot
2017-10-17 08:08:28 +00:00
@@ -58,10 +58,10 @@ public class GifImageResource extends ImageResource {
public Drawable getDrawable(Resources resources) { public Drawable getDrawable(Resources resources) {
try { try {
return new FrameSequenceDrawable(mFrameSequence); return new FrameSequenceDrawable(mFrameSequence);
} catch (final Exception e) { } catch (final Throwable t) {
// Malicious gif images can make platform throw different kind of exceptions. Catch // Malicious gif images can make the platform throw different kind of throwables, such
// them all. // as OutOfMemoryError and NullPointerException. Catch them all.
LogUtil.e(LogUtil.BUGLE_TAG, "Error getting drawable for GIF", e); LogUtil.e(LogUtil.BUGLE_TAG, "Error getting drawable for GIF", t);
return null; return null;
} }
} }