Skip to content

Commit

Permalink
snapcraft/wrappers/editor: fix EDIT_PATH_HOST mangling
Browse files Browse the repository at this point in the history
Signed-off-by: Simon Deziel <[email protected]>
  • Loading branch information
simondeziel authored and tomponline committed Dec 11, 2023
1 parent 461786a commit e51b34d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion snapcraft/wrappers/editor
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ fi
if [ -n "${EDIT_CMD}" ] && [ "${USERNS}" = 1 ]; then
exec 9< /tmp/
# Replace "/tmp/" prefix by exec'ed FD 9.
EDIT_PATH_HOST="/proc/self/fd/9/$(echo "${EDIT_PATH}" | cut -d/ -f2)"
EDIT_PATH_HOST="/proc/self/fd/9/$(echo "${EDIT_PATH}" | cut -d/ -f3)"
find_and_spawn "${EDIT_CMD}" "${EDIT_PATH_HOST}"
fi

Expand Down

0 comments on commit e51b34d

Please sign in to comment.