diff options
author | cyBerta <cyberta@riseup.net> | 2021-07-15 00:06:24 +0200 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2021-07-21 22:02:28 +0200 |
commit | b2705ea702a9eaa4a0f5566ed70cdfb4f41390d3 (patch) | |
tree | 41bee173c49ffd96e94e9c1680b68da4db85426e /app | |
parent | aa43298684367000cadf16037cb90c366ac3c000 (diff) |
don't set a new ClientTransportPlugin everytime a service connection has been initiated with TorService
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java | 4 |
1 files changed, 3 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 15843697..15e77576 100644 --- a/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java +++ b/app/src/main/java/se/leap/bitmaskclient/providersetup/ProviderAPI.java @@ -192,7 +192,9 @@ public class ProviderAPI extends JobIntentService implements ProviderApiManagerB try { if (torServiceConnection == null) { Log.d(TAG, "serviceConnection is still null"); - TorService.setClientTransportPlugin(new ClientTransportPlugin(context.getApplicationContext())); + if (!TorService.hasClientTransportPlugin()) { + TorService.setClientTransportPlugin(new ClientTransportPlugin(context.getApplicationContext())); + } torServiceConnection = new TorServiceConnection(context); } } catch (InterruptedException | IllegalStateException e) { |