summaryrefslogtreecommitdiffhomepage
path: root/android/service
diff options
context:
space:
mode:
authorJonatan Rhodin <jonatan.rhodin@mullvad.net>2023-10-27 15:13:25 +0200
committerDavid Lönnhager <david.l@mullvad.net>2023-10-31 00:45:17 +0100
commit64756a535e04aea34bc8101eb4f3e83f52e426cb (patch)
treed75fc82796fd5982b5980455a302519bec24e2e8 /android/service
parent5c491337ba76b999137fa4c0071ed5b6e0079eb4 (diff)
downloadmullvadvpn-64756a535e04aea34bc8101eb4f3e83f52e426cb.tar.xz
mullvadvpn-64756a535e04aea34bc8101eb4f3e83f52e426cb.zip
Add from java support for relay settings
Diffstat (limited to 'android/service')
-rw-r--r--android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/MullvadDaemon.kt5
-rw-r--r--android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/endpoint/RelayListListener.kt3
2 files changed, 3 insertions, 5 deletions
diff --git a/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/MullvadDaemon.kt b/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/MullvadDaemon.kt
index 0b9e15774a..fd734bbeac 100644
--- a/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/MullvadDaemon.kt
+++ b/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/MullvadDaemon.kt
@@ -289,10 +289,7 @@ class MullvadDaemon(
playPurchase: PlayPurchase,
): PlayPurchaseVerifyResult
- private external fun setRelaySettings(
- daemonInterfaceAddress: Long,
- update: RelaySettings
- )
+ private external fun setRelaySettings(daemonInterfaceAddress: Long, update: RelaySettings)
private external fun setObfuscationSettings(
daemonInterfaceAddress: Long,
diff --git a/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/endpoint/RelayListListener.kt b/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/endpoint/RelayListListener.kt
index 2fc1e4115a..7a0b3fbe97 100644
--- a/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/endpoint/RelayListListener.kt
+++ b/android/service/src/main/kotlin/net/mullvad/mullvadvpn/service/endpoint/RelayListListener.kt
@@ -91,7 +91,8 @@ class RelayListListener(endpoint: ServiceEndpoint) {
val location: Constraint<LocationConstraint> =
selectedRelayLocation?.let { location ->
Constraint.Only(LocationConstraint.Location(location))
- } ?: currentRelayConstraints.location
+ }
+ ?: currentRelayConstraints.location
val wireguardConstraints: WireguardConstraints =
selectedWireguardConstraints ?: currentRelayConstraints.wireguardConstraints