diff options
author | Werner Koch <[email protected]> | 2018-04-12 18:36:30 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2018-04-12 18:36:30 +0000 |
commit | b99502274ae5efdf6df0d967900ec3d1e64373d7 (patch) | |
tree | 9cb32e50e31e664986ec6c618b8a247a1c7f3862 /src/op-support.c | |
parent | core: For a failed verification return the sig's fingerprint. (diff) | |
download | gpgme-b99502274ae5efdf6df0d967900ec3d1e64373d7.tar.gz gpgme-b99502274ae5efdf6df0d967900ec3d1e64373d7.zip |
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 <[email protected]>
Diffstat (limited to 'src/op-support.c')
-rw-r--r-- | src/op-support.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/op-support.c b/src/op-support.c index 43cb1c76..e55875f9 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); } |