chiark
/
gitweb
/
~ianmdlvl
/
secnet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19a171f
)
Work around Bison's crazy redeclaration of malloc/free.
author
Richard Kettlewell
<rjk@greenend.org.uk>
Sun, 19 Jun 2011 16:57:28 +0000
(17:57 +0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sun, 26 Jun 2011 11:07:28 +0000
(12:07 +0100)
Signed-off-by: Richard Kettlewell <richard@greenend.org.uk>
conffile.y
patch
|
blob
|
history
diff --git
a/conffile.y
b/conffile.y
index 1625122fe762f4a83831eda9c9b3ad55bfd3201b..7837abe651365c12e460f4492db4f39da5f825d6 100644
(file)
--- a/
conffile.y
+++ b/
conffile.y
@@
-8,6
+8,12
@@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+/* Bison stupidly redeclares malloc/free unless they are #defined
+ * (or a bunch of madder conditions) */
+#ifndef malloc
+# define malloc malloc
+# define free free
+#endif
#include "secnet.h"
#include "conffile_internal.h"
#include "conffile.yy.h"