summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2020-02-26 12:07:11 +0100
committerWerner Koch <wk@gnupg.org>2020-02-26 12:07:11 +0100
commit9d268891dae6093e5346710a38ba8cd978f24f09 (patch)
tree62442b228f20276493db4b2030b90dca40abb04a /tests
parent6fc2d7cb8ce9e08cb189608466803ee7c8eb6930 (diff)
downloadlibgpg-error-9d268891dae6093e5346710a38ba8cd978f24f09.tar.gz
core: Prepare argparse.c to track additional info for options.
* src/argparse.c (opttable_t): New. (struct _gpgrt_argparse_internal_s): Use this instead of a ppointer to gpgrt_opt_t. (initialize): Copy options to the new tableand keep an original ordinal. (_gpgrt_argparse): Adjust for changes. (any_opt_conffile): Ditto. (find_long_option): Ditto. (arg_parse): Ditto. (long_opt_strlen): Adjust args. (cmp_ordtbl): New. (show_help): Print using the ordinal numbers. -- We will need to keep extra information along with the options. This changes prepares this by using a copy of the user provided option table. The only new info is the original ordinal number which will allow us to eventually do a binary search on the options but still be able to print the help in the user defined way. GnuPG-bug-id: 4788 Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions