From aad94cb7c313d4501bed748f48830cbb93c67e20 Mon Sep 17 00:00:00 2001
From: Werner Koch <wk@gnupg.org>
Date: Thu, 3 Nov 2016 16:29:45 +0100
Subject: core: Add gpgme_op_query_swdb and helper.

* src/gpgme.h.in (gpgme_query_swdb_result_t): New.
(gpgme_op_query_swdb): New.
(gpgme_op_query_swdb_result): New.
* src/libgpgme.vers, src/gpgme.def: Add the two new functions.
* src/queryswdb.c: New.
* src/Makefile.am (main_sources): Add new file.
* src/context.h (OPDATA_QUERY_SWDB): New.
* src/engine-backend.h (struct engine_ops): Add field 'query_swdb'.
Adjust all initializer.
* src/engine.c (_gpgme_engine_op_query_swdb): New.
* src/engine-gpgconf.c (parse_swdb_line): New.
(gpgconf_query_swdb): New.
(_gpgme_engine_ops_gpgconf): Register that function.

* src/util.h (GPG_ERR_TOO_OLD): Define for older libgpg-error.
(GPG_ERR_ENGINE_TOO_OLD): Ditto.

* tests/run-swdb.c: New.
* tests/Makefile.am (noinst_PROGRAMS): Add new debug tool.

Signed-off-by: Werner Koch <wk@gnupg.org>
---
 src/gpgme.def | 3 +++
 1 file changed, 3 insertions(+)

(limited to 'src/gpgme.def')

diff --git a/src/gpgme.def b/src/gpgme.def
index d633df57..2f6837da 100644
--- a/src/gpgme.def
+++ b/src/gpgme.def
@@ -249,5 +249,8 @@ EXPORTS
     gpgme_set_sender                      @187
     gpgme_get_sender                      @188
 
+    gpgme_op_query_swdb                   @189
+    gpgme_op_query_swdb_result            @190
+
 ; END
 
-- 
cgit v1.2.3

