diff options
Diffstat (limited to 'ui/src/main')
-rw-r--r-- | ui/src/main/java/com/wireguard/android/Application.kt | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/ui/src/main/java/com/wireguard/android/Application.kt b/ui/src/main/java/com/wireguard/android/Application.kt index c66c52bd..06903af4 100644 --- a/ui/src/main/java/com/wireguard/android/Application.kt +++ b/ui/src/main/java/com/wireguard/android/Application.kt @@ -58,10 +58,6 @@ class Application : android.app.Application() { startActivity(intent) System.exit(0) } - if (BuildConfig.DEBUG) { - StrictMode.setVmPolicy(VmPolicy.Builder().detectAll().penaltyLog().build()) - StrictMode.setThreadPolicy(ThreadPolicy.Builder().detectAll().penaltyLog().build()) - } } private suspend fun determineBackend(): Backend { @@ -119,6 +115,11 @@ class Application : android.app.Application() { Log.e(TAG, Log.getStackTraceString(e)) } } + + if (BuildConfig.DEBUG) { + StrictMode.setVmPolicy(VmPolicy.Builder().detectAll().penaltyLog().build()) + StrictMode.setThreadPolicy(ThreadPolicy.Builder().detectAll().penaltyLog().build()) + } } override fun onTerminate() { |