Fix commit 9f1c5fef1 when building with GpgME < 1.7.0.
authorAndrej Kacian <ticho@claws-mail.org>
Thu, 9 Nov 2017 08:11:35 +0000 (09:11 +0100)
committerAndrej Kacian <ticho@claws-mail.org>
Thu, 9 Nov 2017 08:11:35 +0000 (09:11 +0100)
src/plugins/pgpcore/pgp_viewer.c

index 102b886..074245a 100644 (file)
@@ -278,7 +278,12 @@ static void pgpview_show_mime_part(TextView *textview, MimeInfo *partinfo)
                return;
        } else {
                TEXTVIEW_INSERT(_("\n  Key ID "));
-               TEXTVIEW_INSERT(key->fpr);
+
+               if (gpgme_check_version("1.7.0"))
+                       TEXTVIEW_INSERT(key->fpr);
+               else
+                       TEXTVIEW_INSERT(sig->fpr);
+
                TEXTVIEW_INSERT(":\n\n");
                TEXTVIEW_INSERT(_("   This key is in your keyring.\n"));
        }