Suppress CancellationException again

This commit is contained in:
Mygod
2020-11-04 07:48:43 +08:00
parent d08d6c90c0
commit ee98ea2caf

View File

@@ -7,6 +7,7 @@ import android.system.OsConstants
import be.mygod.vpnhotspot.root.ReadArp import be.mygod.vpnhotspot.root.ReadArp
import be.mygod.vpnhotspot.root.RootManager import be.mygod.vpnhotspot.root.RootManager
import be.mygod.vpnhotspot.util.parseNumericAddress import be.mygod.vpnhotspot.util.parseNumericAddress
import kotlinx.coroutines.CancellationException
import kotlinx.coroutines.runBlocking import kotlinx.coroutines.runBlocking
import timber.log.Timber import timber.log.Timber
import java.io.File import java.io.File
@@ -127,7 +128,7 @@ data class IpNeighbour(val ip: InetAddress, val dev: String, val lladdr: MacAddr
}.value.lineSequence().makeArp() }.value.lineSequence().makeArp()
} catch (eRoot: Exception) { } catch (eRoot: Exception) {
eRoot.addSuppressed(e) eRoot.addSuppressed(e)
Timber.w(eRoot) if (eRoot !is CancellationException) Timber.w(eRoot)
} else Timber.w(e) } else Timber.w(e)
} }
return arpCache return arpCache