summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-04-13 12:34:35 +0200
committerMergify <37929162+mergify[bot]@users.noreply.github.com>2024-04-13 10:38:02 +0000
commit48722ae450d0e7ef36a2318e90be33c244edd20f (patch)
treed17d5020e0c14777af452800388b3a9f0e5ce8b9 /scripts
parent3f594076208027cafdd13f343131ac2d2d3b2445 (diff)
downloadvyos-build-48722ae450d0e7ef36a2318e90be33c244edd20f.tar.gz
vyos-build-48722ae450d0e7ef36a2318e90be33c244edd20f.zip
T6173: fix TypeError: 'NoneType' object is not iterable
Commit 611cfc85c531 ("T6173: validate allowed characters in ISO image name") missed the probability that version is a dict member bot empty. (cherry picked from commit 801def2d7105acc45868c361730e5be5ab4c36ea)
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/build-vyos-image2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/build-vyos-image b/scripts/build-vyos-image
index 716a4cde..141da5e2 100755
--- a/scripts/build-vyos-image
+++ b/scripts/build-vyos-image
@@ -207,7 +207,7 @@ if __name__ == "__main__":
sys.exit(1)
# Validate characters in version name
- if 'version' in args:
+ if 'version' in args and args['version'] != None:
allowed = string.ascii_letters + string.digits + '.' + '-' + '+'
if not set(args['version']) <= set(allowed):
print(f'Version contained illegal character(s), allowed: {allowed}')