Home GnuPG

Add diagnostic button to some error report dialogs.

Description

Add diagnostic button to some error report dialogs.

* src/gpgmetools.c (_gpa_gpgme_warning): Rename to _gpa_gpgme_warn and
add arg CTX.
* src/gpgmetools.h (gpa_gpgme_warn): New macro
(gpa_gpgme_warning, gpa_gpgme_warning_ext): Adjust macros.
* src/gtktools.h: Include gpacontext.h.
* src/gtktools.c (show_gtk_message): Add arg CTX and add button to
show details.
(gpa_show_info): Adjust to provide NULL for new arg.
(gpa_show_warning): Renamed to ...
(gpa_show_warn): this and add arg CTX.  Change all callers to use new
name and to pass NULL for CTX.
* src/gpacontext.h (_GpaContext): Add field inhibit_gpgme_events.
* src/gpacontext.c (gpa_context_get_diag): New.
(gpa_context_event_cb): Inhibit events as needed.
* src/gpafiledecryptop.c (gpa_file_decrypt_operation_done_error_cb):
Pass the gpgme contextto gpa_show_warn or gpa_gpgme_warn.

We need the inhibit thingy because we use gpgme_op_getauditlog in
synchronous mode whilst the context has also been setup for asynchronous
mode for the real operations. This is a peculiarity of getauditevent.

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Oct 15 2018, 4:53 PM
Parents
rGPAf160e92d908e: Let Server->Retrieve_Key use --locate-key for a mail address.
Branches
Unknown
Tags
Unknown