aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2025-08-27 08:33:19 +0000
committerWerner Koch <[email protected]>2025-08-27 08:33:19 +0000
commitdb794de6205212ab22feb5c79cc0f07b312f4043 (patch)
treede8d3e1a7be6270feffc2f314f4ba338b60536f6
parentgpg: Allow to select the Kyber variant with --edit-key,addkey. (diff)
downloadgnupg-db794de6205212ab22feb5c79cc0f07b312f4043.tar.gz
gnupg-db794de6205212ab22feb5c79cc0f07b312f4043.zip
gpgsm: Change the debug flags used with --debug-level basic to expert.
* sm/gpgsm.c (set_debug): Do not set the IPC debug flag when using some debug-levels.
-rw-r--r--doc/gpgsm.texi9
-rw-r--r--sm/gpgsm.c6
2 files changed, 8 insertions, 7 deletions
diff --git a/doc/gpgsm.texi b/doc/gpgsm.texi
index 5bba67d6a..7dab314be 100644
--- a/doc/gpgsm.texi
+++ b/doc/gpgsm.texi
@@ -801,8 +801,8 @@ The option has an effect only on Windows.
@item --debug-level @var{level}
@opindex debug-level
-Select the debug level for investigating problems. @var{level} may be
-a numeric value or by a keyword:
+Select the debug level for investigating problems. @var{level} may be
+a numeric value or a keyword:
@table @code
@item none
@@ -824,8 +824,9 @@ only enabled if the keyword is used.
@end table
How these messages are mapped to the actual debugging flags is not
-specified and may change with newer releases of this program. They are
-however carefully selected to best aid in debugging.
+specified and may change with newer releases of this program. This is
+a legacy option; in general it is better to select specific debug
+flags using the @option{--debug}.
@item --debug @var{flags}
@opindex debug
diff --git a/sm/gpgsm.c b/sm/gpgsm.c
index 4614938c2..319002b07 100644
--- a/sm/gpgsm.c
+++ b/sm/gpgsm.c
@@ -777,11 +777,11 @@ set_debug (void)
else if (!strcmp (debug_level, "none") || (numok && numlvl < 1))
opt.debug = 0;
else if (!strcmp (debug_level, "basic") || (numok && numlvl <= 2))
- opt.debug = DBG_IPC_VALUE;
+ opt.debug = DBG_MEMSTAT_VALUE;
else if (!strcmp (debug_level, "advanced") || (numok && numlvl <= 5))
- opt.debug = DBG_IPC_VALUE|DBG_X509_VALUE;
+ opt.debug = DBG_MEMSTAT_VALUE|DBG_X509_VALUE;
else if (!strcmp (debug_level, "expert") || (numok && numlvl <= 8))
- opt.debug = (DBG_IPC_VALUE|DBG_X509_VALUE
+ opt.debug = (DBG_MEMSTAT_VALUE|DBG_X509_VALUE
|DBG_CACHE_VALUE|DBG_CRYPTO_VALUE);
else if (!strcmp (debug_level, "guru") || numok)
{