From a4ca22f419832cd32b1ba64bef92cd51ff73e122 Mon Sep 17 00:00:00 2001 From: tibbi Date: Mon, 13 Feb 2017 23:31:24 +0100 Subject: [PATCH] catch out of memory error at editor activity too --- .../com/simplemobiletools/gallery/activities/EditActivity.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt index 38d430577..1f23b9417 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/EditActivity.kt @@ -149,6 +149,8 @@ class EditActivity : SimpleActivity(), CropImageView.OnCropImageCompleteListener Log.e(TAG, "Crop compressing failed $path $e") toast(R.string.image_editing_failed) finish() + } catch (e: OutOfMemoryError) { + toast(R.string.unknown_error_occurred) } finally { try { out?.close()