[Pkg-privacy-commits] [onionshare] 06/16: Only check if we are in the sys prefix but not the actual executable name as this could be renamed or wrapped
Ulrike Uhlig
ulrike at moszumanska.debian.org
Fri May 26 12:51:56 UTC 2017
This is an automated email from the git hooks/post-receive script.
ulrike pushed a commit to branch debian
in repository onionshare.
commit 4f464aaf2c84fc88d330ad31f1276bdc24b2b3ab
Author: xSmurf <xsmurf at users.noreply.github.com>
Date: Wed Sep 28 17:24:28 2016 +0000
Only check if we are in the sys prefix but not the actual executable name as this could be renamed or wrapped
---
onionshare/helpers.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/onionshare/helpers.py b/onionshare/helpers.py
index aaa1c99..33a46ce 100644
--- a/onionshare/helpers.py
+++ b/onionshare/helpers.py
@@ -34,7 +34,7 @@ def get_resource_path(filename):
systemwide, and whether regardless of platform
"""
p = get_platform()
- if p == 'Linux' and sys.argv and sys.argv[0].startswith('/usr/bin/onionshare'):
+ if p == 'Linux' and sys.argv and sys.argv[0].startswith(sys.prefix):
# OnionShare is installed systemwide in Linux
resources_dir = os.path.join(sys.prefix, 'share/onionshare')
elif getattr(sys, 'frozen', False): # Check if app is "frozen" with cx_Freeze
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/onionshare.git
More information about the Pkg-privacy-commits
mailing list