From 5fa53f752458107ecfc49c4a58fb87123193fdfa Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Mon, 26 Apr 2004 13:46:36 +0000 Subject: * scdaemon.c (main): Do the last change the usual way. This is so that we can easily test for versioned config files above. * gpgsm.c (main) : Do not use /dev/null as default config filename. --- scd/scdaemon.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'scd/scdaemon.c') diff --git a/scd/scdaemon.c b/scd/scdaemon.c index d0306aeb6..5e9737ae4 100644 --- a/scd/scdaemon.c +++ b/scd/scdaemon.c @@ -539,8 +539,6 @@ main (int argc, char **argv ) if (gpgconf_list) { - char *filename; - /* List options and default values in the GPG Conf format. */ /* The following list is taken from gnupg/tools/gpgconf-comp.c. */ @@ -559,11 +557,11 @@ main (int argc, char **argv ) /* The NO_ARG_DESC flag for an option indicates that the argument has a default, which is described by the value of the ARGDEF field. */ #define GC_OPT_FLAG_NO_ARG_DESC (1UL << 6) + if (!config_filename) + config_filename = make_filename (opt.homedir, "scdaemon.conf", NULL ); - filename = make_filename (opt.homedir, "scdaemon.conf", NULL); printf ("gpgconf-scdaemon.conf:%lu:\"%s\n", - GC_OPT_FLAG_DEFAULT, filename); - xfree (filename); + GC_OPT_FLAG_DEFAULT, config_filename); printf ("verbose:%lu:\n" "quiet:%lu:\n" -- cgit v1.2.3