diff options
author | Werner Koch <wk@gnupg.org> | 2015-08-25 09:03:31 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2015-08-25 15:26:33 +0200 |
commit | 9cdff09743c473a12359bfdb914578ede0e4e3e2 (patch) | |
tree | ecad07063ec0abab01e9e29eca601d7ee33ef5ee /common | |
parent | agent: Raise the maximum password length. Don't hard code it. (diff) | |
download | gnupg2-9cdff09743c473a12359bfdb914578ede0e4e3e2.tar.xz gnupg2-9cdff09743c473a12359bfdb914578ede0e4e3e2.zip |
gpg: Print a new FAILURE status after most commands.
* common/status.h (STATUS_FAILURE): New.
* g10/cpr.c (write_status_failure): New.
* g10/gpg.c (main): Call write_status_failure for all commands which
print an error message here.
* g10/call-agent.c (start_agent): Print an STATUS_ERROR if we can't
set the pinentry mode.
--
This status line can be used similar to the error code returned by
commands send over the Assuan interface in gpgsm. We don't emit them
in gpgsm because there we already have that Assuan interface to return
proper error code. This change helps GPGME to return better error
codes.
Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/status.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/common/status.h b/common/status.h index 3c78eda08..f1af5877c 100644 --- a/common/status.h +++ b/common/status.h @@ -126,9 +126,10 @@ enum STATUS_ERROR, STATUS_SUCCESS, + STATUS_FAILURE, - STATUS_INQUIRE_MAXLEN, -}; + STATUS_INQUIRE_MAXLEN + }; const char *get_status_string (int code); |