Skip to content

Commit 5eafc6b

Browse files
Kerin Millarthesamesam
authored andcommitted
special_env_vars.py: add GLOBSORT to the environ_filter set
The traditional behaviour of bash has been to sort the words produced by pathname expansion by name, in ascending lexicographical order, and in accordance with the collation defined by the 'LC_COLLATE' variable. However, bash-5.3 introduces the new 'GLOBSORT' variable which provides a means of controlling how the words are sorted. For example, setting GLOBSORT="-mtime" will sort by reverse order of modification time. Given that bash is capable of inheriting this variable from its process environment, portage must not be allowed to propagate the variable to the "ebuild.sh" utility or any other programs that it executes. To that end, incorporate the 'GLOBSORT' variable into the 'environ_filter' set defined by the "special_env_vars.py" unit. See-also: 8a607ed Signed-off-by: Kerin Millar <[email protected]> Signed-off-by: Sam James <[email protected]>
1 parent 4cf0144 commit 5eafc6b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/portage/package/ebuild/_config/special_env_vars.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,7 @@
265265
"MANPATH",
266266
"USER",
267267
# variables that break bash
268+
"GLOBSORT",
268269
"HISTFILE",
269270
"POSIXLY_CORRECT",
270271
# portage config variables and variables set directly by portage

0 commit comments

Comments
 (0)