aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2024-05-15 13:25:18 -0400
committerMike Gilbert <floppym@gentoo.org>2024-05-21 13:24:00 -0400
commita33065dab4bebd476d0dcba3c1659fbe0e515469 (patch)
tree753fbe859fad43c140dca9cda9045f65f6efcfd1 /bin
parentSchedulerInterface/PollScheduler: _loadavg_latency's unit is seconds (diff)
downloadportage-a33065dab4bebd476d0dcba3c1659fbe0e515469.tar.gz
portage-a33065dab4bebd476d0dcba3c1659fbe0e515469.tar.bz2
portage-a33065dab4bebd476d0dcba3c1659fbe0e515469.zip
Do not use shlex.split for CONFIG_PROTECT
PMS says this is a whitespace-separated list, so we should not treat it as a shell expression. Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'bin')
-rwxr-xr-xbin/dispatch-conf4
-rwxr-xr-xbin/portageq8
2 files changed, 6 insertions, 6 deletions
diff --git a/bin/dispatch-conf b/bin/dispatch-conf
index 601110ce8..e34e9587f 100755
--- a/bin/dispatch-conf
+++ b/bin/dispatch-conf
@@ -202,7 +202,7 @@ class dispatch:
protect_obj = portage.util.ConfigProtect(
config_root,
config_paths,
- portage.util.shlex_split(portage.settings.get("CONFIG_PROTECT_MASK", "")),
+ portage.settings.get("CONFIG_PROTECT_MASK", "").split(),
case_insensitive=("case-insensitive-fs" in portage.settings.features),
)
@@ -616,4 +616,4 @@ if len(sys.argv) > 1:
# for testing
d.grind(sys.argv[1:])
else:
- d.grind(portage.util.shlex_split(portage.settings.get("CONFIG_PROTECT", "")))
+ d.grind(portage.settings.get("CONFIG_PROTECT", "").split())
diff --git a/bin/portageq b/bin/portageq
index 93fa4edeb..9ef0cb7d6 100755
--- a/bin/portageq
+++ b/bin/portageq
@@ -410,8 +410,8 @@ try:
from portage.util import ConfigProtect
settings = portage.settings
- protect = portage.util.shlex_split(settings.get("CONFIG_PROTECT", ""))
- protect_mask = portage.util.shlex_split(settings.get("CONFIG_PROTECT_MASK", ""))
+ protect = settings.get("CONFIG_PROTECT", "").split()
+ protect_mask = settings.get("CONFIG_PROTECT_MASK", "").split()
protect_obj = ConfigProtect(
root,
protect,
@@ -449,8 +449,8 @@ try:
from portage.util import ConfigProtect
settings = portage.settings
- protect = portage.util.shlex_split(settings.get("CONFIG_PROTECT", ""))
- protect_mask = portage.util.shlex_split(settings.get("CONFIG_PROTECT_MASK", ""))
+ protect = settings.get("CONFIG_PROTECT", "").split()
+ protect_mask = settings.get("CONFIG_PROTECT_MASK", "").split()
protect_obj = ConfigProtect(
root,
protect,