summaryrefslogtreecommitdiff
path: root/app/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/java')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java b/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java
index 15e77576..322bf1cd 100644
--- a/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java
+++ b/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java
@@ -168,7 +168,10 @@ public class ProviderAPI extends JobIntentService implements ProviderApiManagerB
getApplicationContext().startService(torServiceIntent);
}
- return torServiceConnection.torService.getHttpTunnelPort();
+ int tunnelPort = torServiceConnection.torService.getHttpTunnelPort();
+ torServiceConnection.close();
+ torServiceConnection = null;
+ return tunnelPort;
}
return -1;