Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8ed6b6a9 authored by Romain Guy's avatar Romain Guy Committed by Android (Google) Code Review
Browse files

Merge "Perform a long computation to catch bitmap sizes > 32 bits Bug #7257930" into jb-mr1-dev

parents 955b66d0 af61cc4c
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -12811,8 +12811,8 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
            final boolean opaque = drawingCacheBackgroundColor != 0 || isOpaque();
            final boolean use32BitCache = attachInfo != null && attachInfo.mUse32BitDrawingCache;
            final int projectedBitmapSize = width * height * (opaque && !use32BitCache ? 2 : 4);
            final int drawingCacheSize =
            final long projectedBitmapSize = width * height * (opaque && !use32BitCache ? 2 : 4);
            final long drawingCacheSize =
                    ViewConfiguration.get(mContext).getScaledMaximumDrawingCacheSize();
            if (width <= 0 || height <= 0 || projectedBitmapSize > drawingCacheSize) {
                if (width > 0 && height > 0) {