Prepare for release 0.5.9 (#68)

Updated the yggdrasil-go submodule. Fixed #64, updated some deps.
This commit is contained in:
Revertron 2024-10-23 18:10:01 +02:00 committed by GitHub
parent 34756b2193
commit cdc12a8e7e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 22 additions and 12 deletions

View file

@ -6,6 +6,7 @@
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_SYSTEM_EXEMPTED" />
<application
android:name=".GlobalApplication"
@ -42,6 +43,7 @@
<service
android:name=".PacketTunnelProvider"
android:permission="android.permission.BIND_VPN_SERVICE"
android:foregroundServiceType="systemExempted"
android:exported="true">
<intent-filter>
<action android:name="android.net.VpnService" />

View file

@ -68,6 +68,7 @@ class MainActivity : AppCompatActivity() {
startVpnActivity.launch(vpnIntent)
} else {
start()
enabledSwitch.isEnabled = false
}
}
false -> {
@ -181,6 +182,9 @@ class MainActivity : AppCompatActivity() {
else -> getString(R.string.main_many_peers, count)
}
}
if (!enabledSwitch.isEnabled) {
enabledSwitch.isEnabled = true
}
}
}
}

View file

@ -232,7 +232,11 @@ open class PacketTunnelProvider: VpnService() {
}
private fun updater() {
Thread.sleep(500)
try {
Thread.sleep(500)
} catch (_: InterruptedException) {
return
}
var lastStateUpdate = System.currentTimeMillis()
updates@ while (started.get()) {
val treeJSON = yggdrasil.treeJSON