Fix potential crash
This commit is contained in:
parent
6d0abb928e
commit
2ae19260fb
@ -52,4 +52,5 @@ dependencies {
|
||||
implementation(project(":libs:owncloud"))
|
||||
implementation(project(":core:i18n"))
|
||||
implementation(project(":core:permissions"))
|
||||
implementation(project(":core:crashreporter"))
|
||||
}
|
||||
@ -15,6 +15,7 @@ import android.text.format.DateUtils
|
||||
import android.util.Size
|
||||
import androidx.core.content.FileProvider
|
||||
import androidx.exifinterface.media.ExifInterface
|
||||
import de.mm20.launcher2.crashreporter.CrashReporter
|
||||
import de.mm20.launcher2.files.R
|
||||
import de.mm20.launcher2.icons.*
|
||||
import de.mm20.launcher2.ktx.formatToString
|
||||
@ -291,6 +292,10 @@ data class LocalFile(
|
||||
}
|
||||
retriever.release()
|
||||
} catch (e: RuntimeException) {
|
||||
CrashReporter.logException(e)
|
||||
} catch (e: IOException) {
|
||||
CrashReporter.logException(e)
|
||||
} finally {
|
||||
retriever.release()
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user