diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt index c8805198..b6c82bc4 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt @@ -34,10 +34,10 @@ abstract class IpMonitor : Runnable { monitor.errorStream.bufferedReader().forEachLine { Crashlytics.log(Log.ERROR, javaClass.simpleName, it) } - } catch (e: IOException) { + } catch (_: InterruptedIOException) { } catch (e: IOException) { e.printStackTrace() Crashlytics.logException(e) - } catch (_: InterruptedIOException) { } + } } try { monitor.inputStream.bufferedReader().forEachLine(this::processLine) @@ -48,10 +48,10 @@ abstract class IpMonitor : Runnable { val pool = Executors.newScheduledThreadPool(1) pool.scheduleAtFixedRate(this, 1, 1, TimeUnit.SECONDS) this.pool = pool - } catch (e: IOException) { + } catch (_: InterruptedIOException) { } catch (e: IOException) { e.printStackTrace() Crashlytics.logException(e) - } catch (_: InterruptedIOException) { } + } } }