From 6fcc263c182fc49d9ba2d1bd7649b4af1e9f3e3a Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Thu, 10 Sep 2020 12:14:02 +0200 Subject: keyboxd: Use D-lines instead of a separate thread. * kbx/kbx-client-util.c (kbx_client_data_new): Add arg 'dlines'. * g10/call-keyboxd.c (open_context): Set DLINES to true. * sm/keydb.c (open_context): Ditto. -- This allows to compile time switch between the D-line and the fd-passing data communication between gpg/gpgsm and keyboxd. A quick test with about 3000 OpenPGP keys showed that D-lines are only 10% slower than the fd-passing based implementation. Given that the thread adds extra complexity we go for now with the D-line approach. Signed-off-by: Werner Koch --- kbx/kbx-client-util.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'kbx/kbx-client-util.h') diff --git a/kbx/kbx-client-util.h b/kbx/kbx-client-util.h index db6cb9475..1cc68b5a0 100644 --- a/kbx/kbx-client-util.h +++ b/kbx/kbx-client-util.h @@ -26,7 +26,7 @@ struct kbx_client_data_s; typedef struct kbx_client_data_s *kbx_client_data_t; gpg_error_t kbx_client_data_new (kbx_client_data_t *r_kcd, - assuan_context_t ctx); + assuan_context_t ctx, int dlines); void kbx_client_data_release (kbx_client_data_t kcd); gpg_error_t kbx_client_data_cmd (kbx_client_data_t kcd, const char *command, gpg_error_t (*status_cb)(void *opaque, -- cgit v1.2.3