From a082b9ee241b56ea55a2f59baa2fc42d941154e4 Mon Sep 17 00:00:00 2001 From: "James O. D. Hunt" Date: Tue, 3 Apr 2018 10:05:51 +0100 Subject: [PATCH] scripts: Add extra check to hypervisor config script Check the specified tag in `check_tag()` to ensure it is not blank (which is invalid). Signed-off-by: James O. D. Hunt --- scripts/configure-hypervisor.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/configure-hypervisor.sh b/scripts/configure-hypervisor.sh index ddab519184..102c194fe2 100755 --- a/scripts/configure-hypervisor.sh +++ b/scripts/configure-hypervisor.sh @@ -92,6 +92,8 @@ check_tag() local tag="$1" local entry="$2" + [ -z "$tag" ] && die "no tag for entry '$entry'" + value="${recognised_tags[$tag]}" [ -n "$value" ] && return