summaryrefslogtreecommitdiffstats
path: root/kbx/keyboxd.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2020-03-14 18:53:43 +0100
committerWerner Koch <wk@gnupg.org>2020-03-14 19:12:41 +0100
commit451cd1b3928172b312ca2597c3318e6e9e8be97d (patch)
tree3f8b8aa7052753d26a585e71a5861a35786e5ebc /kbx/keyboxd.c
parentgpg: New option --auto-key-import (diff)
downloadgnupg2-451cd1b3928172b312ca2597c3318e6e9e8be97d.tar.xz
gnupg2-451cd1b3928172b312ca2597c3318e6e9e8be97d.zip
gpgconf: Further simplify the gpgconf option processing.
* common/gc-opt-flags.h (GC_OPT_FLAG_RUNTIME): Move to ... * tools/gpgconf-comp.c: here. (known_options_scdaemon): Remove "options". (known_options_dirmngr): Remove "options". (known_options_gpgsm): Remove "options". (known_options_gpg): Remove "options" and "keyserver". (struct gc_option_s): Rename active t gpgconf_list. (gc_component_list_options): Do not act upon active. (option_check_validity): Ditto. (is_known_option): Make it work correctly for unknown options. (retrieve_options_from_program): Use renamed flag gpgconf_list only to detect duplicated items from --gpgconf-list. Do not set runtime. Only e set the options if set by --gpgconf-list; never clear them. * agent/gpg-agent.c: Simplify the --gpgconf-list output. * dirmngr/dirmngr.c: Ditto. * g10/gpg.c: Ditto. * kbx/keyboxd.c: Ditto. * scd/scdaemon.c: Ditto. * sm/gpgsm.c: Ditto. * tests/openpgp/gpgconf.scm: Use "compliance" instead of "keyserver" for the string arg test. -- There is no need to read the list of options from the components unless they convey a default value. It is better to consult only the list we have in gpgconf-comp.c to decide on whether an option should be displayed. Right, this might mess up thing if a newer gpgconf version is used with an older component, but we already print warnings in this case and in general we do not want to support this anymore - the times of gpg 1.4. and 2.0 are long over now. GnuPG-bug-id: 4788 Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'kbx/keyboxd.c')
-rw-r--r--kbx/keyboxd.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/kbx/keyboxd.c b/kbx/keyboxd.c
index ffcd0a3fb..5acac97a5 100644
--- a/kbx/keyboxd.c
+++ b/kbx/keyboxd.c
@@ -670,26 +670,6 @@ main (int argc, char **argv )
kbxd_exit (0);
else if (gpgconf_list)
{
- char *filename;
- char *filename_esc;
-
- /* List options and default values in the gpgconf format. */
- filename = make_filename (gnupg_homedir (),
- "keyboxd" EXTSEP_S "conf", NULL);
- filename_esc = percent_escape (filename, NULL);
-
- es_printf ("%s-%s.conf:%lu:\"%s\n",
- GPGCONF_NAME, "keyboxd", GC_OPT_FLAG_DEFAULT, filename_esc);
- xfree (filename);
- xfree (filename_esc);
-
- es_printf ("verbose:%lu:\n"
- "quiet:%lu:\n"
- "log-file:%lu:\n",
- GC_OPT_FLAG_NONE|GC_OPT_FLAG_RUNTIME,
- GC_OPT_FLAG_NONE|GC_OPT_FLAG_RUNTIME,
- GC_OPT_FLAG_NONE|GC_OPT_FLAG_RUNTIME );
-
kbxd_exit (0);
}