diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt index 53a70a411..d8423670e 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/MainActivity.kt @@ -476,6 +476,8 @@ class MainActivity : SimpleActivity(), DirectoryAdapter.DirOperationsListener { inputStream = FileInputStream(File(path)) outputStream = contentResolver.openOutputStream(output) inputStream.copyTo(outputStream) + } catch (e: SecurityException) { + showErrorToast(e) } catch (ignored: FileNotFoundException) { } finally { inputStream?.close()