summaryrefslogtreecommitdiffstats
path: root/g10/gpg.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2016-09-01 19:22:48 +0200
committerWerner Koch <wk@gnupg.org>2016-09-01 19:22:48 +0200
commit38d369de13acb95208a0ed8d1cf82ac19173688f (patch)
tree4bdce0049b30fbcb461fc6c603db59d8442dd50f /g10/gpg.c
parentgpg: Simplify code to print VALIDSIG. (diff)
downloadgnupg2-38d369de13acb95208a0ed8d1cf82ac19173688f.tar.xz
gnupg2-38d369de13acb95208a0ed8d1cf82ac19173688f.zip
gpg: Avoid homedir creation by --list-config
* g10/gpg.c (main): Do not register a key for the list config commands. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'g10/gpg.c')
-rw-r--r--g10/gpg.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/g10/gpg.c b/g10/gpg.c
index a9770d74a..0b0fb7e75 100644
--- a/g10/gpg.c
+++ b/g10/gpg.c
@@ -2377,11 +2377,16 @@ main (int argc, char **argv)
{
switch( pargs.r_opt )
{
- case aCheckKeys:
case aListConfig:
case aListGcryptConfig:
case aGPGConfList:
case aGPGConfTest:
+ set_cmd (&cmd, pargs.r_opt);
+ /* Do not register a keyring for these commands. */
+ default_keyring = -1;
+ break;
+
+ case aCheckKeys:
case aListPackets:
case aImport:
case aFastImport:
@@ -3789,6 +3794,8 @@ main (int argc, char **argv)
case aGenRandom:
case aDeArmor:
case aEnArmor:
+ case aListConfig:
+ case aListGcryptConfig:
break;
case aFixTrustDB:
case aExportOwnerTrust: