From 37f0432e983f11e3bfa29842edd42ad66dd1a25e Mon Sep 17 00:00:00 2001 From: Lyndon Brown Date: Fri, 6 Mar 2020 00:53:44 +0000 Subject: fix inadequate chroot_archives validation commit d74f2102a0849838eb4e15950b01d49f9f79392f added a validation check to chroot_archives for its 'pass' parameter. this was based upon finding an instance where the wrong value was being submitted to the script and wanting to ensure such mistakes would be caught. unfortunately it seems that I made a mistake in misremembering the facts surrounding the latter issue when constructing the validation check and failed to double check with testing until it was already merged. a correction is needed. the set of valid values is not limited to only 'source|binary' but actually 'source|binary|chroot'. I'd misremembered 'chroot' as being a completely invalid value. --- scripts/build/chroot_archives | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/build/chroot_archives b/scripts/build/chroot_archives index 8f83906f0..472b76785 100755 --- a/scripts/build/chroot_archives +++ b/scripts/build/chroot_archives @@ -16,12 +16,13 @@ set -e # Setting static variables DESCRIPTION="Manage /etc/apt/sources.list" HELP="" -USAGE="${PROGRAM} {source|binary} {install|remove} [--force]" +USAGE="${PROGRAM} {source|binary|chroot} {install|remove} [--force]" _PASS="${1}" shift -if [ "${_PASS}" != "binary" ] && [ "${_PASS}" != "source" ]; then +if [ "${_PASS}" != "binary" ] && [ "${_PASS}" != "chroot" ] && [ "${_PASS}" != "source" ] +then Usage fi -- cgit v1.2.3