summaryrefslogtreecommitdiff
path: root/accel-pppd
diff options
context:
space:
mode:
authorGuillaume Nault <g.nault@alphalink.fr>2018-10-24 16:36:07 +0200
committerDmitry Kozlov <xeb@mail.ru>2018-10-26 06:34:34 +0300
commitda574d66ab7f21dc6678447b8ced874b50ead534 (patch)
treea3ccd6a8533ad9e78a2f358fe92f0d868291dbd8 /accel-pppd
parentf0a2a6df8d82d0a3c250e5291a21603fe6e00e5b (diff)
downloadaccel-ppp-xebd-da574d66ab7f21dc6678447b8ced874b50ead534.tar.gz
accel-ppp-xebd-da574d66ab7f21dc6678447b8ced874b50ead534.zip
memdebug: make memdebug.h self-contained even when MEMDEBUG isn't defined
We need to include <stdio.h> to define 'asprintf', <stdlib.h> for 'malloc', 'realloc' and 'free' and <string.h> for 'strdup' and 'strndup'. Signed-off-by: Guillaume Nault <g.nault@alphalink.fr>
Diffstat (limited to 'accel-pppd')
-rw-r--r--accel-pppd/memdebug.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/accel-pppd/memdebug.h b/accel-pppd/memdebug.h
index 09978f4..501b882 100644
--- a/accel-pppd/memdebug.h
+++ b/accel-pppd/memdebug.h
@@ -21,6 +21,11 @@ int md_asprintf(const char *fname, int line, char **strp, const char *fmt, ...)
void md_check(void *ptr);
#else
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
#define _malloc(size) malloc(size)
#define _realloc(ptr, size) realloc(ptr, size)
#define _free(ptr) free(ptr)