summaryrefslogtreecommitdiffstats
path: root/dirmngr/domaininfo.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2023-03-10 10:52:43 +0100
committerWerner Koch <wk@gnupg.org>2023-03-10 11:24:48 +0100
commit56ca164684b69bcb20eb98a1adc70531c8991576 (patch)
tree981e54860b4f08f035ba61a01999d1453432d635 /dirmngr/domaininfo.c
parentagent: Try to SETREPEATOK if the pinentry supports it. (diff)
downloadgnupg2-56ca164684b69bcb20eb98a1adc70531c8991576.tar.xz
gnupg2-56ca164684b69bcb20eb98a1adc70531c8991576.zip
dirmngr: Add command "GETINFO stats".
* dirmngr/server.c (cmd_getinfo): New sub-command "stats". (dirmngr_status_helpf): Allow for a CTRL of NULL. * dirmngr/certcache.c (cert_cache_print_stats): Add arg ctrl and use dirmngr_status_helpf. Adjust all callers. * dirmngr/domaininfo.c (domaininfo_print_stats): Ditto. * sm/certchain.c (ask_marktrusted): Flush stdout before printing the fingerprint.
Diffstat (limited to 'dirmngr/domaininfo.c')
-rw-r--r--dirmngr/domaininfo.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/dirmngr/domaininfo.c b/dirmngr/domaininfo.c
index b41aef366..b6043be53 100644
--- a/dirmngr/domaininfo.c
+++ b/dirmngr/domaininfo.c
@@ -81,7 +81,7 @@ hash_domain (const char *domain)
void
-domaininfo_print_stats (void)
+domaininfo_print_stats (ctrl_t ctrl)
{
int bidx;
domaininfo_t di;
@@ -112,11 +112,12 @@ domaininfo_print_stats (void)
if (minlen == -1 || len < minlen)
minlen = len;
}
- log_info ("domaininfo: items=%d chainlen=%d..%d nn=%d nf=%d ns=%d s=%d\n",
- count,
- minlen > 0? minlen : 0,
- maxlen,
- no_name, wkd_not_found, wkd_not_supported, wkd_supported);
+ dirmngr_status_helpf
+ (ctrl, "domaininfo: items=%d chainlen=%d..%d nn=%d nf=%d ns=%d s=%d\n",
+ count,
+ minlen > 0? minlen : 0,
+ maxlen,
+ no_name, wkd_not_found, wkd_not_supported, wkd_supported);
}