diff options
Diffstat (limited to 'bin/eselect.in')
-rwxr-xr-x | bin/eselect.in | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/eselect.in b/bin/eselect.in index 36581e1..ee26b80 100755 --- a/bin/eselect.in +++ b/bin/eselect.in @@ -62,7 +62,8 @@ umask +rx # Sanitise PATH: We don't want to execute Portage's internal helpers # if we're called from an ebuild. IFS=: -read -r -d '' -a path < <(printf '%s\0' "${PATH}") +# Append ${IFS} to prevent any trailing empty field from being dropped +set -f; path=(${PATH}${IFS}); set +f for i in "${!path[@]}"; do [[ ${path[i]} == */portage?(/*)/ebuild-helpers?(/*) ]] && unset "path[i]" done |