Find the proper tor binary in onionshare-cli for macOS

This commit is contained in:
Micah Lee 2020-11-04 15:22:27 -08:00
parent 68347039c9
commit d9153758cd
No known key found for this signature in database
GPG key ID: 403C2657CD994F73
2 changed files with 24 additions and 11 deletions

View file

@ -328,6 +328,10 @@ class Onion(object):
f.write(self.settings.get("tor_bridges_use_custom_bridges"))
f.write("\nUseBridges 1")
# Make sure the tor path is accurate
if not os.path.exists(self.tor_path):
raise BundledTorNotSupported(f"Cannot find tor binary: {self.tor_path}")
# Execute a tor subprocess
start_ts = time.time()
if self.common.platform == "Windows":