commit 10c65fe9146092902ec80580386ec7955c4dfcb8
parent c56ee766b98962cf019fea4f362de5235d603fec
Author: Colin Leroy <colin@colino.net>
Date: Mon, 19 May 2008 20:24:39 +0000
2008-05-19 [colin] 3.4.0cvs55
* src/plugins/pgpcore/sgpgme.c
Maybe fix debian bug 481856, 'Segmentation fault
when verifying a GPG signature'. Although it
looks like a race condition...
Diffstat:
4 files changed, 19 insertions(+), 4 deletions(-)
diff --git a/ChangeLog b/ChangeLog
@@ -1,3 +1,10 @@
+2008-05-19 [colin] 3.4.0cvs55
+
+ * src/plugins/pgpcore/sgpgme.c
+ Maybe fix debian bug 481856, 'Segmentation fault
+ when verifying a GPG signature'. Although it
+ looks like a race condition...
+
2008-05-19 [colin] 3.4.0cvs54
* src/prefs_filtering_action.c
diff --git a/PATCHSETS b/PATCHSETS
@@ -3350,3 +3350,4 @@
( cvs diff -u -r 1.274.2.241 -r 1.274.2.242 src/mainwindow.c; ) > 3.4.0cvs52.patchset
( cvs diff -u -r 1.105.2.131 -r 1.105.2.132 src/prefs_account.c; ) > 3.4.0cvs53.patchset
( cvs diff -u -r 1.1.4.50 -r 1.1.4.51 src/prefs_filtering_action.c; cvs diff -u -r 1.43.2.72 -r 1.43.2.73 src/prefs_matcher.c; cvs diff -u -r 1.1.2.6 -r 1.1.2.7 src/common/tags.c; cvs diff -u -r 1.1.2.3 -r 1.1.2.4 src/common/tags.h; cvs diff -u -r 1.1.2.12 -r 1.1.2.13 src/gtk/combobox.c; cvs diff -u -r 1.1.2.10 -r 1.1.2.11 src/gtk/combobox.h; ) > 3.4.0cvs54.patchset
+( cvs diff -u -r 1.1.2.50 -r 1.1.2.51 src/plugins/pgpcore/sgpgme.c; ) > 3.4.0cvs55.patchset
diff --git a/configure.ac b/configure.ac
@@ -11,7 +11,7 @@ MINOR_VERSION=4
MICRO_VERSION=0
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=54
+EXTRA_VERSION=55
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=
diff --git a/src/plugins/pgpcore/sgpgme.c b/src/plugins/pgpcore/sgpgme.c
@@ -258,11 +258,18 @@ gchar *sgpgme_sigstat_info_full(gpgme_ctx_t ctx, gpgme_verify_result_t status)
while (sig) {
gpgme_user_id_t user = NULL;
gpgme_key_t key;
-
+ gpgme_error_t err;
const gchar *keytype, *keyid, *uid;
- gpgme_get_key(ctx, sig->fpr, &key, 0);
+ err = gpgme_get_key(ctx, sig->fpr, &key, 0);
+ if (err != GPG_ERR_NO_ERROR) {
+ key = NULL;
+ g_string_append_printf(siginfo,
+ _("Error checking signature: %s\n"),
+ gpgme_strerror(err));
+ goto bail;
+ }
if (key) {
user = key->uids;
keytype = gpgme_pubkey_algo_name(
@@ -332,7 +339,7 @@ gchar *sgpgme_sigstat_info_full(gpgme_ctx_t ctx, gpgme_verify_result_t status)
i++;
sig = sig->next;
}
-
+bail:
ret = siginfo->str;
g_string_free(siginfo, FALSE);
return ret;