mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-21 14:47:03 +01:00
gpgscm: Build well even if NDEBUG defined.
* gpgscm/scheme.c (gc_reservation_failure): Fix adding ";". [!NDEBUG] (scheme_init_custom_alloc): Don't init seserved_lineno. -- Cherry icked from master commit of: e140c6d4f581be1a60a34b67b16430452f3987e8 In some build environment, NDEBUG is defined (although it's bad practice). This change supports such a situation. GnuPG-bug-id: 3959 Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
parent
14e5435afb
commit
8161afb9dd
@ -874,7 +874,7 @@ gc_reservation_failure(struct scheme *sc)
|
||||
{
|
||||
#ifdef NDEBUG
|
||||
fprintf(stderr,
|
||||
"insufficient reservation\n")
|
||||
"insufficient reservation\n");
|
||||
#else
|
||||
fprintf(stderr,
|
||||
"insufficient %s reservation in line %d\n",
|
||||
@ -5627,7 +5627,9 @@ int scheme_init_custom_alloc(scheme *sc, func_alloc malloc, func_dealloc free) {
|
||||
sc->fcells = 0;
|
||||
sc->inhibit_gc = GC_ENABLED;
|
||||
sc->reserved_cells = 0;
|
||||
#ifndef NDEBUG
|
||||
sc->reserved_lineno = 0;
|
||||
#endif
|
||||
sc->no_memory=0;
|
||||
sc->inport=sc->NIL;
|
||||
sc->outport=sc->NIL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user