Commit 02e10607 authored by Mygod's avatar Mygod

Sometimes Android manages to miss the most obvious

parent 42ad20fe
......@@ -177,10 +177,13 @@ class VpnService : BaseVpnService(), LocalDnsService.Interface {
when (profile.route) {
Acl.ALL, Acl.BYPASS_CHN, Acl.CUSTOM_RULES -> builder.addRoute("0.0.0.0", 0)
else -> resources.getStringArray(R.array.bypass_private_route).forEach {
else -> {
resources.getStringArray(R.array.bypass_private_route).forEach {
val subnet = Subnet.fromString(it)!!
builder.addRoute(subnet.address.hostAddress, subnet.prefixSize)
}
builder.addRoute(PRIVATE_VLAN4_ROUTER, 32)
}
}
active = true // possible race condition here?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment