projects
/
kconfig-hardened-check.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Show error if some cmdline option exists multiple times
[kconfig-hardened-check.git]
/
kconfig_hardened_check
/
__init__.py
diff --git
a/kconfig_hardened_check/__init__.py
b/kconfig_hardened_check/__init__.py
index a423358b932d8dd3cb82a6e5c9c64259d856e3b7..572ed0ab6f7467e42bfa50256b0fe9d8cd4f4889 100644
(file)
--- a/
kconfig_hardened_check/__init__.py
+++ b/
kconfig_hardened_check/__init__.py
@@
-193,6
+193,8
@@
def parse_cmdline_file(parsed_options, fname):
else:
name = opt
value = '' # '' is not None
+ if name in parsed_options:
+ sys.exit(f'[!] ERROR: cmdline option "{name}" exists multiple times')
value = normalize_cmdline_options(name, value)
parsed_options[name] = value