diff options
author | Andre Heinecke <[email protected]> | 2019-01-15 07:36:26 +0000 |
---|---|---|
committer | Andre Heinecke <[email protected]> | 2019-01-15 07:36:26 +0000 |
commit | ce327f994a2888b807b63cf202ddcecc3fb9c685 (patch) | |
tree | 94d9e8e5f7ac72f872c5a9c061d164b90f56553a /tests/run-import.c | |
parent | qt: Use tofu conflict test keys without expiry (diff) | |
download | gpgme-ce327f994a2888b807b63cf202ddcecc3fb9c685.tar.gz gpgme-ce327f994a2888b807b63cf202ddcecc3fb9c685.zip |
tests: Add diagnostic example to run-import.c
* tests/run-import.c (main): Show diagnostics in verbose mode.
Diffstat (limited to 'tests/run-import.c')
-rw-r--r-- | tests/run-import.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/run-import.c b/tests/run-import.c index a3c52ac0..d98871c3 100644 --- a/tests/run-import.c +++ b/tests/run-import.c @@ -125,6 +125,20 @@ main (int argc, char **argv) gpgme_data_release (data); } + if (verbose) + { + gpgme_data_t log; + char *buf; + size_t len; + + gpgme_data_new (&log); + err = gpgme_op_getauditlog (ctx, log, GPGME_AUDITLOG_DIAG); + fail_if_err (err); + buf = gpgme_data_release_and_get_mem (log, &len); + printf ("\nDiagnostic output:\n%.*s\n", len, buf); + free (buf); + } + gpgme_release (ctx); return 0; } |