summaryrefslogtreecommitdiffstats
path: root/kbx
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2022-09-14 09:49:31 +0200
committerNIIBE Yutaka <gniibe@fsij.org>2022-09-14 09:53:35 +0200
commitd55728539f0edfa660dc24775d3dfd1471aebd3b (patch)
tree0c6dbc48c02784fb6b86d43c46dbb2c5794b0532 /kbx
parentdirmngr: Fix for USE_LDAP. (diff)
downloadgnupg2-d55728539f0edfa660dc24775d3dfd1471aebd3b.tar.xz
gnupg2-d55728539f0edfa660dc24775d3dfd1471aebd3b.zip
kbx: Fix for GPG_ERR_SOURCE_DEFAULT.
* kbx/keybox-defs.h (GPG_ERR_SOURCE_DEFAULT): Define here, when not defined. * kbx/kbxutil.c: Let keybox-defs.h include gpg-error.h. -- GnuPG-bug-id: 6200 Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'kbx')
-rw-r--r--kbx/kbxutil.c3
-rw-r--r--kbx/keybox-defs.h8
2 files changed, 3 insertions, 8 deletions
diff --git a/kbx/kbxutil.c b/kbx/kbxutil.c
index 911514406..f5bc8bd77 100644
--- a/kbx/kbxutil.c
+++ b/kbx/kbxutil.c
@@ -30,12 +30,11 @@
#include <limits.h>
#include <assert.h>
-#include <gpg-error.h>
+#include "keybox-defs.h"
#include "../common/logging.h"
#include "../common/stringhelp.h"
#include "../common/utf8conv.h"
#include "../common/i18n.h"
-#include "keybox-defs.h"
#include "../common/init.h"
#include <gcrypt.h>
diff --git a/kbx/keybox-defs.h b/kbx/keybox-defs.h
index 0af3aafb3..51ba8cd0e 100644
--- a/kbx/keybox-defs.h
+++ b/kbx/keybox-defs.h
@@ -20,12 +20,8 @@
#ifndef KEYBOX_DEFS_H
#define KEYBOX_DEFS_H 1
-#ifdef GPG_ERR_SOURCE_DEFAULT
-# if GPG_ERR_SOURCE_DEFAULT != GPG_ERR_SOURCE_KEYBOX
-# error GPG_ERR_SOURCE_DEFAULT already defined
-# endif
-#else
-# define GPG_ERR_SOURCE_DEFAULT GPG_ERR_SOURCE_KEYBOX
+#ifndef GPG_ERR_SOURCE_DEFAULT
+#define GPG_ERR_SOURCE_DEFAULT GPG_ERR_SOURCE_KEYBOX
#endif
#include <gpg-error.h>
#define map_assuan_err(a) \