From: Adhemerval Zanella Date: Wed, 14 Dec 2022 21:18:34 +0000 (-0300) Subject: elf: Fix tst-relro-symbols.py argument passing X-Git-Tag: glibc-2.37~86 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=71e408e45dcacf429a94b2807f75aaadd8d37cb9;p=thirdparty%2Fglibc.git elf: Fix tst-relro-symbols.py argument passing Current scheme only consideres the first argument for both --required and --optional, where the idea is to append a new item. Checked on x86_64-linux-gnu. Reviewed-by: Florian Weimer --- diff --git a/elf/tst-relro-symbols.py b/elf/tst-relro-symbols.py index 368ea3349f8..ea61024b5eb 100644 --- a/elf/tst-relro-symbols.py +++ b/elf/tst-relro-symbols.py @@ -56,10 +56,10 @@ def get_parser(): """Return an argument parser for this script.""" parser = argparse.ArgumentParser(description=__doc__) parser.add_argument('object', help='path to object file to check') - parser.add_argument('--required', metavar='NAME', default=(), - help='required symbol names', nargs='*') - parser.add_argument('--optional', metavar='NAME', default=(), - help='required symbol names', nargs='*') + parser.add_argument('--required', metavar='NAME', action='append', + default=[], help='required symbol names') + parser.add_argument('--optional', metavar='NAME', action='append', + default=[], help='required symbol names') return parser def main(argv):