Only allow alphanumeric in flavor.

This commit is contained in:
Jesse Keating 2007-12-03 11:56:03 -05:00 committed by Jesse Keating
parent 33a2ec8508
commit a9c124e7e0

4
pungi
View File

@ -175,6 +175,10 @@ if __name__ == '__main__':
parser.print_help() parser.print_help()
sys.exit(0) sys.exit(0)
if not config.get('default', 'flavor').isalnum():
print >> sys.stderr, "Flavor must be alphanumeric."
sys.exit(1)
if opts.do_gather or opts.do_createrepo or opts.do_buildinstall or opts.do_createiso: if opts.do_gather or opts.do_createrepo or opts.do_buildinstall or opts.do_createiso:
opts.do_all = False opts.do_all = False
return (opts, args) return (opts, args)