]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
scripts/cve-json-to-text.py: simplify getopt argument parsing
authorBin Cao <bin.cao.cn@windriver.com>
Mon, 20 Apr 2026 02:42:37 +0000 (10:42 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 28 Apr 2026 13:28:14 +0000 (14:28 +0100)
Remove unused long options from getopt.getopt() call. The long options
"help", "input", and "output" were never handled in the option parsing
logic, so they are dead code.

Signed-off-by: Bin Cao <bin.cao.cn@windriver.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
scripts/cve-json-to-text.py

index 8d309b37e59326e9efcb77876adb73d1ec536420..f33867226967245c9f5d9857caa93a5c18034d3b 100755 (executable)
@@ -42,9 +42,7 @@ def parse_args(argv):
     """
     global infile, outfile
     try:
-        opts, args = getopt.getopt(
-            argv, "hi:o:", ["help", "input", "output"]
-        )
+        opts, args = getopt.getopt(argv, "hi:o:")
     except getopt.GetoptError:
         show_syntax_and_exit(1)
     for opt, arg in opts: