mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
gpg: Print better diagnostics for keyserver operations.
* g10/armor.c (parse_key_failed_line): New. (check_input): Watch out for gpgkeys_ error lines. * g10/filter.h (armor_filter_context_t): Add field key_failed_code. * g10/import.c (import): Add arg r_gpgkeys_err. (import_keys_internal): Ditto. (import_keys_stream): Ditto. * g10/keyserver.c (keyserver_errstr): New. (keyserver_spawn): Detect "KEY " lines while sending. Get gpgkeys_err while receiving keys. (keyserver_work): Add kludge for better error messages. -- GnuPG-bug-id: 1832 Note that these changes can be backported to 1.4 but they don't make sense for 2.1 due to the removal of the keyserver helpers. The error reporting could be improved even more but given that this is an old GnuPG branch it is not justified to put too much effort into it. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
cb2ee2dc50
commit
0c3d7645df
5 changed files with 122 additions and 22 deletions
|
@ -39,6 +39,8 @@ typedef struct {
|
|||
|
||||
/* these fields must be initialized to zero */
|
||||
int no_openpgp_data; /* output flag: "No valid OpenPGP data found" */
|
||||
int key_failed_code; /* Error code from the first gpgkkeys_*
|
||||
"KEY <keyid> FAILED <err>" line. */
|
||||
|
||||
/* the following fields must be initialized to zero */
|
||||
int inp_checked; /* set if the input has been checked */
|
||||
|
@ -121,7 +123,7 @@ typedef struct {
|
|||
unsigned long last; /* last amount reported */
|
||||
unsigned long offset; /* current amount */
|
||||
unsigned long total; /* total amount */
|
||||
int refcount;
|
||||
int refcount;
|
||||
} progress_filter_context_t;
|
||||
|
||||
/* encrypt_filter_context_t defined in main.h */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue