diff --git a/src/org/thoughtcrime/securesms/CreateProfileActivity.java b/src/org/thoughtcrime/securesms/CreateProfileActivity.java index b69ad2d2fb..fa669bb223 100644 --- a/src/org/thoughtcrime/securesms/CreateProfileActivity.java +++ b/src/org/thoughtcrime/securesms/CreateProfileActivity.java @@ -2,6 +2,7 @@ package org.thoughtcrime.securesms; import android.animation.Animator; +import android.annotation.SuppressLint; import android.app.Activity; import android.content.Context; import android.content.Intent; @@ -66,6 +67,7 @@ import javax.inject.Inject; import static android.provider.MediaStore.EXTRA_OUTPUT; +@SuppressLint("StaticFieldLeak") public class CreateProfileActivity extends BaseActionBarActivity implements InjectableType { private static final String TAG = CreateProfileActivity.class.getSimpleName(); diff --git a/src/org/thoughtcrime/securesms/util/BitmapUtil.java b/src/org/thoughtcrime/securesms/util/BitmapUtil.java index ae6700296a..d4310b8403 100644 --- a/src/org/thoughtcrime/securesms/util/BitmapUtil.java +++ b/src/org/thoughtcrime/securesms/util/BitmapUtil.java @@ -16,6 +16,7 @@ import android.util.Log; import android.util.Pair; import com.bumptech.glide.Glide; +import com.bumptech.glide.load.engine.DiskCacheStrategy; import com.bumptech.glide.load.resource.bitmap.DownsampleStrategy; import org.thoughtcrime.securesms.mms.GlideApp; @@ -55,6 +56,8 @@ public class BitmapUtil { Bitmap scaledBitmap = GlideApp.with(context.getApplicationContext()) .asBitmap() .load(model) + .skipMemoryCache(true) + .diskCacheStrategy(DiskCacheStrategy.NONE) .downsample(DownsampleStrategy.AT_MOST) .submit(constraints.getImageMaxWidth(context), constraints.getImageMaxWidth(context))