[git] GPGME - branch, master, updated. gpgme-1.10.0-188-gb995022

by Werner Koch cvs at cvs.gnupg.org
Thu Apr 12 20:45:16 CEST 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GnuPG Made Easy".

The branch, master has been updated
       via  b99502274ae5efdf6df0d967900ec3d1e64373d7 (commit)
      from  478d1650bbef84958ccce439fac982ef57b16cd0 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit b99502274ae5efdf6df0d967900ec3d1e64373d7
Author: Werner Koch <wk at gnupg.org>
Date:   Thu Apr 12 20:36:30 2018 +0200

    core: Tweak STATUS_FAILURE handling.
    
    * src/op-support.c (_gpgme_parse_failure): Ignore failures with
    location "gpg-exit".
    * tests/gpg/t-verify.c (main): Adjust for the now working checking of
    the second key.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/src/op-support.c b/src/op-support.c
index 43cb1c7..e55875f 100644
--- a/src/op-support.c
+++ b/src/op-support.c
@@ -400,7 +400,13 @@ _gpgme_parse_plaintext (char *args, char **filenamep)
 
 
 /* Parse a FAILURE status line and return the error code.  ARGS is
-   modified to contain the location part.  */
+ * modified to contain the location part.  Note that for now we ignore
+ * failure codes with a location of gpg-exit; they are too trouble
+ * some.  Instead we should eventually record that error in the
+ * context and provide a function to return a fuller error
+ * description; this could then also show the location of the error
+ * (e.g. "option- parser") to make it easier for the user to detect
+ * the actual error. */
 gpgme_error_t
 _gpgme_parse_failure (char *args)
 {
@@ -418,6 +424,8 @@ _gpgme_parse_failure (char *args)
     *where = '\0';
 
   where = args;
+  if (!strcmp (where, "gpg-exit"))
+    return 0;
 
   return atoi (which);
 }
diff --git a/tests/gpg/t-verify.c b/tests/gpg/t-verify.c
index ffc41ee..7c23406 100644
--- a/tests/gpg/t-verify.c
+++ b/tests/gpg/t-verify.c
@@ -267,10 +267,12 @@ main (int argc, char *argv[])
   err = gpgme_op_verify (ctx, sig, text, NULL);
   fail_if_err (err);
   result = gpgme_op_verify_result (ctx);
-  check_result (result, 2, 0, 0, "A0FF4590BB6122EDEF6E3C542D727CC768697734",
+  check_result (result, 2, 0, 0,
+                "A0FF4590BB6122EDEF6E3C542D727CC768697734",
 		GPG_ERR_NO_ERROR, 1);
-  check_result (result, 2, 1, 0, "36EC2A70C6426EB0FCE5BB4DF91C98F049D4204C",
-		GPG_ERR_NO_ERROR, 0);
+  check_result (result, 2, 1, GPGME_SIGSUM_KEY_MISSING,
+                "36EC2A70C6426EB0FCE5BB4DF91C98F049D4204C",
+		GPG_ERR_NO_PUBKEY, 0);
 
 
   /* Checking a normal signature.  */

-----------------------------------------------------------------------

Summary of changes:
 src/op-support.c     | 10 +++++++++-
 tests/gpg/t-verify.c |  8 +++++---
 2 files changed, 14 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list