From: Christoph Hohmann Date: Fri, 24 Oct 2003 19:21:29 +0000 (+0000) Subject: 0.9.6claws50 X-Git-Tag: rel_0_9_7~61 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=ed264059a571ed0a51e95dea8ccafbc1a778d681;hp=f843d3ea82c6b5b013e4e323d0919e77772d6d57 0.9.6claws50 * src/sgpgme.c change fetching of signature key's trust --- diff --git a/ChangeLog.claws b/ChangeLog.claws index 8c742783d..1eaa8ceec 100644 --- a/ChangeLog.claws +++ b/ChangeLog.claws @@ -1,3 +1,8 @@ +2003-10-24 [paul] 0.9.6claws50 + + * src/sgpgme.c + change fetching of signature key's trust + 2003-10-24 [paul] 0.9.6claws49 * po/sk.po diff --git a/configure.ac b/configure.ac index e37627cf4..54c413145 100644 --- a/configure.ac +++ b/configure.ac @@ -11,7 +11,7 @@ MINOR_VERSION=9 MICRO_VERSION=6 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=49 +EXTRA_VERSION=50 if test $EXTRA_VERSION -eq 0; then VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}claws else diff --git a/src/sgpgme.c b/src/sgpgme.c index 391f0883b..179fff728 100644 --- a/src/sgpgme.c +++ b/src/sgpgme.c @@ -100,20 +100,17 @@ static const gchar *get_validity_str(unsigned long validity) gchar *sgpgme_sigstat_info_short(GpgmeCtx ctx, GpgmeSigStat status) { - GpgmeKey key; - switch (status) { case GPGME_SIG_STAT_GOOD: { - unsigned long validity = 0, val, i; + GpgmeKey key; + unsigned long validity = 0; - if (gpgme_get_sig_key(ctx, 0, &key) != GPGME_No_Error) - return g_strdup(_("Error")); - - i = 0; - while ((val = gpgme_key_get_ulong_attr(key, GPGME_ATTR_VALIDITY, NULL, i++)) > 0) - if (val > validity) - validity = val; + if (gpgme_get_sig_key(ctx, 0, &key) != GPGME_No_Error) + return g_strdup(_("Error")); + + validity = gpgme_get_sig_ulong_attr(ctx, 0, + GPGME_ATTR_VALIDITY, 0); return g_strdup_printf(_("Valid signature by %s (Trust: %s)"), gpgme_key_get_string_attr(key, GPGME_ATTR_USERID, NULL, 0),