summaryrefslogtreecommitdiff
path: root/testrecurse.c
diff options
context:
space:
mode:
Diffstat (limited to 'testrecurse.c')
-rw-r--r--testrecurse.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/testrecurse.c b/testrecurse.c
index e5d5d1b..bdc7c30 100644
--- a/testrecurse.c
+++ b/testrecurse.c
@@ -10,8 +10,11 @@
* daniel@veillard.com
*/
+#ifdef HAVE_CONFIG_H
#include "libxml.h"
+#else
#include <stdio.h>
+#endif
#if !defined(_WIN32) || defined(__CYGWIN__)
#include <unistd.h>
@@ -146,6 +149,10 @@ static void globfree(glob_t *pglob) {
}
}
+#if !defined(__MINGW32__)
+#define vsnprintf _vsnprintf
+#define snprintf _snprintf
+#endif
#else
#include <glob.h>
#endif
@@ -680,10 +687,12 @@ recursiveDetectTest(const char *filename,
xmlDocPtr doc;
xmlParserCtxtPtr ctxt;
int res = 0;
+ int mem;
nb_tests++;
ctxt = xmlNewParserCtxt();
+ mem = xmlMemUsed();
/*
* base of the test, parse with the old API
*/
@@ -719,10 +728,12 @@ notRecursiveDetectTest(const char *filename,
xmlDocPtr doc;
xmlParserCtxtPtr ctxt;
int res = 0;
+ int mem;
nb_tests++;
ctxt = xmlNewParserCtxt();
+ mem = xmlMemUsed();
/*
* base of the test, parse with the old API
*/