[git] GPGME - branch, master, updated. gpgme-1.11.1-48-g998fec8

by Werner Koch cvs at cvs.gnupg.org
Tue Jun 5 09:49:06 CEST 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GnuPG Made Easy".

The branch, master has been updated
       via  998fec8a4fbc46315fe6836980954eed402b38c5 (commit)
      from  897423422b9d3b856bfb72fbe1995b91d153a54e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 998fec8a4fbc46315fe6836980954eed402b38c5
Author: Werner Koch <wk at gnupg.org>
Date:   Tue Jun 5 09:40:17 2018 +0200

    json: Allow to compile with libgpg-error < 1.28
    
    * src/cJSON.c: Use gpgrt fucntion only if available.
    --
    
    We have a hack in gpgme-json to allow building with older libgpg-error
    versions.  That whole thing will not work but the instead the binary
    will print an error at runtime that it needs to be build with a newer
    libgcrypt.  There was a little bug here for the Debian packages
    libgpg-error versions which failed to build cJSON.  cJSON is only
    needed be the full gpgme-json but nevertheless the Makefile wants to
    build it.  The fix is straightforward.
    
    GnuPG-bug-id: 3971
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/src/cJSON.c b/src/cJSON.c
index cf0cb13..38cb152 100644
--- a/src/cJSON.c
+++ b/src/cJSON.c
@@ -41,13 +41,13 @@
 #include "cJSON.h"
 
 /* We use malloc function wrappers from gpgrt (aka libgpg-error).  */
-#if 1
+#if GPGRT_VERSION_NUMBER >= 0x011c00 /* 1.28 */
 # include <gpgrt.h>
 # define xtrymalloc(a)   gpgrt_malloc ((a))
 # define xtrycalloc(a,b) gpgrt_calloc ((a), (b))
 # define xtrystrdup(a)   gpgrt_strdup ((a))
 # define xfree(a)        gpgrt_free ((a))
-#else
+#else /* Without gpgrt (aka libgpg-error).  */
 # define xtrymalloc(a)   malloc ((a))
 # define xtrycalloc(a,b) calloc ((a), (b))
 # define xtrystrdup(a)   strdup ((a))

-----------------------------------------------------------------------

Summary of changes:
 src/cJSON.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list