gpgconf: Also print revision of libksba.

* dirmngr/dirmngr.c (get_revision_from_blurb): Fix detection of empty
string.
(gpgconf_versions): Print ksba revision.
--

The latest Libksba version support retrieving of the revision (commit)
id.  We now use that or print a question mark.

Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
Werner Koch 2020-11-19 09:06:31 +01:00
parent 8ddadbbdbb
commit 4070f302e4
No known key found for this signature in database
GPG Key ID: E3FDFF218E45B72B
1 changed files with 4 additions and 3 deletions

View File

@ -2348,7 +2348,7 @@ get_revision_from_blurb (const char *blurb, int *r_len)
for (; *s; s++)
if (*s == '\n' && s[1] == '(')
break;
if (s)
if (*s)
{
s += 2;
for (n=0; s[n] && s[n] != ' '; n++)
@ -2380,8 +2380,9 @@ gpgconf_versions (void)
es_fprintf (es_stdout, "* Libassuan %s (%.*s)\n\n",
assuan_check_version (NULL), n, s);
es_fprintf (es_stdout, "* KSBA %s \n\n",
ksba_check_version (NULL));
s = get_revision_from_blurb (ksba_check_version ("\x01\x01"), &n);
es_fprintf (es_stdout, "* KSBA %s (%.*s)\n\n",
ksba_check_version (NULL), n, s);
#ifdef HTTP_USE_NTBTLS
s = get_revision_from_blurb (ntbtls_check_version ("\x01\x01"), &n);