From f49e2982e5bf147949ae09d2e0f8b791ec8cc6db Mon Sep 17 00:00:00 2001 From: Juan Cruz Viotti Date: Fri, 17 Jun 2016 15:12:15 -0400 Subject: [PATCH] Resolve AppImage binary path correctly when running it as root (#490) Currently, when the AppImage was being ran as `root` we would attempt to run `./usr/bin/etcher`, assuming we were inside the AppDir already and the relative path would resolve correctly. Signed-off-by: Juan Cruz Viotti --- scripts/elevate-linux.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/elevate-linux.sh b/scripts/elevate-linux.sh index ca650377..519182ad 100755 --- a/scripts/elevate-linux.sh +++ b/scripts/elevate-linux.sh @@ -35,7 +35,7 @@ error() { # Check if we're running as root if [ "$EUID" -eq 0 ]; then - ./$binary + $APPDIR/$binary else # Determine a unique mountpoint based on the current mount point.