diff options
Diffstat (limited to 'lib/gnutls_mem.h')
-rw-r--r-- | lib/gnutls_mem.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/lib/gnutls_mem.h b/lib/gnutls_mem.h index 2526ec8d58..959757a27f 100644 --- a/lib/gnutls_mem.h +++ b/lib/gnutls_mem.h @@ -11,15 +11,24 @@ typedef void svoid; /* for functions that allocate using gnutls_secure_malloc */ * memory leaks may occur in systems which do not * support alloca. */ +#ifdef USE_EFENCE +# define gnutls_alloca gnutls_malloc +# define gnutls_afree gnutls_free +#endif + #ifdef HAVE_ALLOCA # ifdef HAVE_ALLOCA_H # include <alloca.h> # endif -# define gnutls_alloca alloca -# define gnutls_afree(x) +# ifndef gnutls_alloca +# define gnutls_alloca alloca +# define gnutls_afree(x) +# endif #else -# define gnutls_alloca gnutls_malloc -# define gnutls_afree gnutls_free +# ifndef gnutls_alloca +# define gnutls_alloca gnutls_malloc +# define gnutls_afree gnutls_free +# endif #endif /* HAVE_ALLOCA */ typedef void* (*gnutls_alloc_function)(size_t); |