integrated in "make tests" added -q option, and more conditional features

* Makefile.am gentest.py testapi.c: integrated in "make tests"
  added -q option, and more conditional features fixes
* catalog.c debugXML.c parser.c testThreads.c xmllint.c
  xmlschemastypes.c xmlwriter.cinclude/libxml/catalog.h
  include/libxml/debugXML.h: various compilation and conditional
  cleanups.
* doc/*: regenerated
Daniel
diff --git a/ChangeLog b/ChangeLog
index 9d4224e..2d8c02e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+Tue Nov  9 17:15:46 CET 2004 Daniel Veillard <daniel@veillard.com>
+
+	* Makefile.am gentest.py testapi.c: integrated in "make tests"
+	  added -q option, and more conditional features fixes
+	* catalog.c debugXML.c parser.c testThreads.c xmllint.c
+	  xmlschemastypes.c xmlwriter.cinclude/libxml/catalog.h
+	  include/libxml/debugXML.h: various compilation and conditional
+	  cleanups.
+	* doc/*: regenerated
+
 Tue Nov  9 15:59:50 CET 2004 Daniel Veillard <daniel@veillard.com>
 
 	* gentest.py testapi.c: better handling of conditional features
diff --git a/Makefile.am b/Makefile.am
index 90a41e3..b186b45 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -130,7 +130,7 @@
 
 testall : tests SVGtests SAXtests
 
-tests: XMLtests XMLenttests NStests IDtests Errtests @READER_TEST@ @TEST_SAX@ @TEST_PUSH@ @TEST_HTML@ @TEST_PHTML@  @TEST_VALID@ URItests @TEST_XPATH@ @TEST_XPTR@ @TEST_XINCLUDE@ @TEST_C14N@ @TEST_DEBUG@ @TEST_CATALOG@ @TEST_REGEXPS@ @TEST_SCHEMAS@ @TEST_THREADS@ Timingtests @TEST_VTIME@ @PYTHON_TESTS@
+tests: XMLtests XMLenttests NStests IDtests Errtests APItests @READER_TEST@ @TEST_SAX@ @TEST_PUSH@ @TEST_HTML@ @TEST_PHTML@  @TEST_VALID@ URItests @TEST_XPATH@ @TEST_XPTR@ @TEST_XINCLUDE@ @TEST_C14N@ @TEST_DEBUG@ @TEST_CATALOG@ @TEST_REGEXPS@ @TEST_SCHEMAS@ @TEST_THREADS@ Timingtests @TEST_VTIME@ @PYTHON_TESTS@
 	@(if [ "@PYTHON_SUBDIR@" != "" ] ; then cd python ; \
 	    $(MAKE) MAKEFLAGS+=--silent tests ; fi)
 	@(cd doc/examples ; $(MAKE) MAKEFLAGS+=--silent tests)
@@ -140,6 +140,10 @@
 	@echo '## Go get a cup of coffee it is gonna take a while ...'
 	$(MAKE) CHECKER='valgrind -q' tests
 
+APItests: testapi$(EXEEXT)
+	@echo "## Running the API regression tests this may take a little while"
+	-@($(CHECKER) $(top_builddir)/testapi -q)
+
 HTMLtests : testHTML$(EXEEXT)
 	@(echo > .memdump)
 	@echo "## HTML regression tests"
diff --git a/catalog.c b/catalog.c
index 4ca29ac..3168efd 100644
--- a/catalog.c
+++ b/catalog.c
@@ -878,9 +878,11 @@
 
     ctxt = xmlNewParserCtxt();
     if (ctxt == NULL) {
+#ifdef LIBXML_SAX1_ENABLED
 	if (xmlDefaultSAXHandler.error != NULL) {
 	    xmlDefaultSAXHandler.error(NULL, "out of memory\n");
 	}
+#endif
 	return(NULL);
     }
 
diff --git a/debugXML.c b/debugXML.c
index 5ab0836..1b8fd70 100644
--- a/debugXML.c
+++ b/debugXML.c
@@ -1772,6 +1772,7 @@
         return("False");
 }
 
+#ifdef LIBXML_XPATH_ENABLED
 /****************************************************************
  *								*
  *	 	The XML shell related functions			*
@@ -3198,4 +3199,5 @@
         free(cmdline);          /* not xmlFree here ! */
 }
 
+#endif /* LIBXML_XPATH_ENABLED */
 #endif /* LIBXML_DEBUG_ENABLED */
diff --git a/doc/APIchunk10.html b/doc/APIchunk10.html
index 8981369..65f6f7b 100644
--- a/doc/APIchunk10.html
+++ b/doc/APIchunk10.html
@@ -45,6 +45,8 @@
 <a href="html/libxml-entities.html#xmlInitializePredefinedEntities">xmlInitializePredefinedEntities</a><br />
 <a href="html/libxml-nanoftp.html#xmlNanoFTPRead">xmlNanoFTPRead</a><br />
 <a href="html/libxml-nanohttp.html#xmlNanoHTTPRead">xmlNanoHTTPRead</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriterPushParser">xmlNewTextWriterPushParser</a><br />
 <a href="html/libxml-parserInternals.html#xmlParseReference">xmlParseReference</a><br />
 <a href="html/libxml-parser.html#xmlSAXUserParseFile">xmlSAXUserParseFile</a><br />
 <a href="html/libxml-parser.html#xmlSAXUserParseMemory">xmlSAXUserParseMemory</a><br />
@@ -291,6 +293,7 @@
 <a href="html/libxml-xmlsave.html#xmlSaveToIO">xmlSaveToIO</a><br />
 <a href="html/libxml-xmlreader.html#xmlTextReaderClose">xmlTextReaderClose</a><br />
 </dd><dt>closed</dt><dd><a href="html/libxml-parser.html#xmlCtxtReadFd">xmlCtxtReadFd</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
 <a href="html/libxml-parser.html#xmlReadFd">xmlReadFd</a><br />
 <a href="html/libxml-xmlreader.html#xmlReaderForFd">xmlReaderForFd</a><br />
 <a href="html/libxml-xmlreader.html#xmlReaderNewFd">xmlReaderNewFd</a><br />
diff --git a/doc/APIchunk11.html b/doc/APIchunk11.html
index e24a542..ef399a3 100644
--- a/doc/APIchunk11.html
+++ b/doc/APIchunk11.html
@@ -54,6 +54,7 @@
 <a href="html/libxml-entities.html#xmlEncodeSpecialChars">xmlEncodeSpecialChars</a><br />
 <a href="html/libxml-parser.html#xmlGetFeaturesList">xmlGetFeaturesList</a><br />
 <a href="html/libxml-hash.html#xmlHashFree">xmlHashFree</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
 <a href="html/libxml-uri.html#xmlSaveUri">xmlSaveUri</a><br />
 <a href="html/libxml-xmlreader.html#xmlTextReaderConstBaseUri">xmlTextReaderConstBaseUri</a><br />
 <a href="html/libxml-xmlreader.html#xmlTextReaderConstEncoding">xmlTextReaderConstEncoding</a><br />
diff --git a/doc/APIchunk13.html b/doc/APIchunk13.html
index 1f22598..8b5c459 100644
--- a/doc/APIchunk13.html
+++ b/doc/APIchunk13.html
@@ -89,6 +89,7 @@
 <a href="html/libxml-tree.html#xmlDocDump">xmlDocDump</a><br />
 <a href="html/libxml-tree.html#xmlDocFormatDump">xmlDocFormatDump</a><br />
 <a href="html/libxml-xmlIO.html#xmlFileOpen">xmlFileOpen</a><br />
+<a href="html/libxml-xmlIO.html#xmlFileRead">xmlFileRead</a><br />
 <a href="html/libxml-list.html#xmlListAppend">xmlListAppend</a><br />
 <a href="html/libxml-list.html#xmlListInsert">xmlListInsert</a><br />
 <a href="html/libxml-nanohttp.html#xmlNanoHTTPFetch">xmlNanoHTTPFetch</a><br />
diff --git a/doc/APIchunk14.html b/doc/APIchunk14.html
index 11e6f70..c31732d 100644
--- a/doc/APIchunk14.html
+++ b/doc/APIchunk14.html
@@ -35,7 +35,8 @@
 <a href="APIchunk25.html">w-w</a>
 <a href="APIchunk26.html">x-x</a>
 <a href="APIchunk27.html">y-z</a>
-</h2><h2>Letter g:</h2><dl><dt>garbage</dt><dd><a href="html/libxml-xmlmemory.html#xmlGcMemGet">xmlGcMemGet</a><br />
+</h2><h2>Letter g:</h2><dl><dt>garanteed</dt><dd><a href="html/libxml-xmlstring.html#xmlUTF8Strsize">xmlUTF8Strsize</a><br />
+</dd><dt>garbage</dt><dd><a href="html/libxml-xmlmemory.html#xmlGcMemGet">xmlGcMemGet</a><br />
 <a href="html/libxml-xmlmemory.html#xmlGcMemSetup">xmlGcMemSetup</a><br />
 </dd><dt>genChRanges</dt><dd><a href="html/libxml-chvalid.html#xmlIsBaseCharQ">xmlIsBaseCharQ</a><br />
 <a href="html/libxml-chvalid.html#xmlIsBaseChar_ch">xmlIsBaseChar_ch</a><br />
diff --git a/doc/APIchunk22.html b/doc/APIchunk22.html
index 175b72e..0765be4 100644
--- a/doc/APIchunk22.html
+++ b/doc/APIchunk22.html
@@ -723,6 +723,7 @@
 <a href="html/libxml-xinclude.html#xmlXIncludeProcessNode">xmlXIncludeProcessNode</a><br />
 <a href="html/libxml-xinclude.html#xmlXIncludeProcessTree">xmlXIncludeProcessTree</a><br />
 <a href="html/libxml-xinclude.html#xmlXIncludeProcessTreeFlags">xmlXIncludeProcessTreeFlags</a><br />
+</dd><dt>succeed</dt><dd><a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
 </dd><dt>succeeded</dt><dd><a href="html/libxml-hash.html#xmlHashAddEntry">xmlHashAddEntry</a><br />
 <a href="html/libxml-hash.html#xmlHashAddEntry2">xmlHashAddEntry2</a><br />
 <a href="html/libxml-hash.html#xmlHashAddEntry3">xmlHashAddEntry3</a><br />
@@ -734,6 +735,7 @@
 <a href="html/libxml-hash.html#xmlHashUpdateEntry3">xmlHashUpdateEntry3</a><br />
 <a href="html/libxml-xpathInternals.html#xmlXPathCompareValues">xmlXPathCompareValues</a><br />
 </dd><dt>succeeds</dt><dd><a href="html/libxml-xmlIO.html#xmlCheckFilename">xmlCheckFilename</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriterPushParser">xmlNewTextWriterPushParser</a><br />
 </dd><dt>successful</dt><dd><a href="html/libxml-catalog.html#xmlACatalogAdd">xmlACatalogAdd</a><br />
 <a href="html/libxml-catalog.html#xmlACatalogRemove">xmlACatalogRemove</a><br />
 <a href="html/libxml-tree.html#xmlBufferAdd">xmlBufferAdd</a><br />
diff --git a/doc/APIchunk25.html b/doc/APIchunk25.html
index 4aa21d1..ac3ff8b 100644
--- a/doc/APIchunk25.html
+++ b/doc/APIchunk25.html
@@ -243,6 +243,8 @@
 <a href="html/libxml-xmlsave.html#xmlSaveToIO">xmlSaveToIO</a><br />
 <a href="html/libxml-debugXML.html#xmlShellWrite">xmlShellWrite</a><br />
 </dd><dt>writer</dt><dd><a href="html/libxml-xmlwriter.html#xmlFreeTextWriter">xmlFreeTextWriter</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriterPushParser">xmlNewTextWriterPushParser</a><br />
 </dd><dt>writes</dt><dd><a href="html/libxml-tree.html#xmlBufferWriteQuotedString">xmlBufferWriteQuotedString</a><br />
 <a href="html/libxml-xmlIO.html#xmlOutputBufferWrite">xmlOutputBufferWrite</a><br />
 <a href="html/libxml-xmlIO.html#xmlOutputBufferWriteEscape">xmlOutputBufferWriteEscape</a><br />
diff --git a/doc/APIchunk4.html b/doc/APIchunk4.html
index 87416e9..f830b7b 100644
--- a/doc/APIchunk4.html
+++ b/doc/APIchunk4.html
@@ -197,6 +197,8 @@
 <a href="html/libxml-tree.html#xmlNewDocNode">xmlNewDocNode</a><br />
 <a href="html/libxml-tree.html#xmlNewDocNodeEatName">xmlNewDocNodeEatName</a><br />
 <a href="html/libxml-tree.html#xmlNewTextChild">xmlNewTextChild</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a><br />
+<a href="html/libxml-xmlwriter.html#xmlNewTextWriterPushParser">xmlNewTextWriterPushParser</a><br />
 <a href="html/libxml-parserInternals.html#xmlParseExternalID">xmlParseExternalID</a><br />
 <a href="html/libxml-parserInternals.html#xmlParsePEReference">xmlParsePEReference</a><br />
 <a href="html/libxml-parserInternals.html#xmlParserHandlePEReference">xmlParserHandlePEReference</a><br />
diff --git a/doc/APIchunk9.html b/doc/APIchunk9.html
index 2ba5141..29a0da4 100644
--- a/doc/APIchunk9.html
+++ b/doc/APIchunk9.html
@@ -121,6 +121,7 @@
 <a href="html/libxml-tree.html#xmlNodeSetSpacePreserve">xmlNodeSetSpacePreserve</a><br />
 <a href="html/libxml-SAX2.html#xmlSAX2ResolveEntity">xmlSAX2ResolveEntity</a><br />
 <a href="html/libxml-xmlreader.html#xmlTextReaderSetParserProp">xmlTextReaderSetParserProp</a><br />
+<a href="html/libxml-xmlstring.html#xmlUTF8Strsize">xmlUTF8Strsize</a><br />
 </dd><dt>below</dt><dd><a href="html/libxml-parser.html#_xmlParserCtxt">_xmlParserCtxt</a><br />
 <a href="html/libxml-parserInternals.html#xmlParseExternalID">xmlParseExternalID</a><br />
 </dd><dt>better</dt><dd><a href="html/libxml-SAX.html#resolveEntity">resolveEntity</a><br />
diff --git a/doc/APIfiles.html b/doc/APIfiles.html
index ee07bd4..cc09f7d 100644
--- a/doc/APIfiles.html
+++ b/doc/APIfiles.html
@@ -2969,6 +2969,7 @@
 <a href="html/libxml-xpath.html#XPATH_EXPR_ERROR">XPATH_EXPR_ERROR</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_ARITY">XPATH_INVALID_ARITY</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CHAR_ERROR">XPATH_INVALID_CHAR_ERROR</a><br />
+<a href="html/libxml-xpath.html#XPATH_INVALID_CTXT">XPATH_INVALID_CTXT</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CTXT_POSITION">XPATH_INVALID_CTXT_POSITION</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CTXT_SIZE">XPATH_INVALID_CTXT_SIZE</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_OPERAND">XPATH_INVALID_OPERAND</a><br />
diff --git a/doc/APIsymbols.html b/doc/APIsymbols.html
index bed8441..b1fd6a6 100644
--- a/doc/APIsymbols.html
+++ b/doc/APIsymbols.html
@@ -1254,6 +1254,7 @@
 <a href="html/libxml-xpath.html#XPATH_EXPR_ERROR">XPATH_EXPR_ERROR</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_ARITY">XPATH_INVALID_ARITY</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CHAR_ERROR">XPATH_INVALID_CHAR_ERROR</a><br />
+<a href="html/libxml-xpath.html#XPATH_INVALID_CTXT">XPATH_INVALID_CTXT</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CTXT_POSITION">XPATH_INVALID_CTXT_POSITION</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_CTXT_SIZE">XPATH_INVALID_CTXT_SIZE</a><br />
 <a href="html/libxml-xpath.html#XPATH_INVALID_OPERAND">XPATH_INVALID_OPERAND</a><br />
diff --git a/doc/examples/reader3.c b/doc/examples/reader3.c
index 2da7532..acbff4f 100644
--- a/doc/examples/reader3.c
+++ b/doc/examples/reader3.c
@@ -15,7 +15,7 @@
 #include <stdio.h>
 #include <libxml/xmlreader.h>
 
-#ifdef LIBXML_READER_ENABLED
+#if defined(LIBXML_READER_ENABLED) && defined(LIBXML_PATTERN_ENABLED)
 
 /**
  * streamFile:
@@ -113,7 +113,7 @@
 
 #else
 int main(void) {
-    fprintf(stderr, "XInclude support not compiled in\n");
+    fprintf(stderr, "Reader or Pattern support not compiled in\n");
     exit(1);
 }
 #endif
diff --git a/doc/examples/tree1.c b/doc/examples/tree1.c
index 8a303e2..8644cf1 100644
--- a/doc/examples/tree1.c
+++ b/doc/examples/tree1.c
@@ -64,10 +64,10 @@
     LIBXML_TEST_VERSION
 
     /*parse the file and get the DOM */
-    doc = xmlParseFile(argv[1]);
+    doc = xmlReadFile(argv[1], NULL, 0);
 
     if (doc == NULL) {
-        printf("error: could not parse file file.xml\n");
+        printf("error: could not parse file %s\n", argv[1]);
     }
 
     /*Get the root element node */
diff --git a/doc/html/libxml-xmlIO.html b/doc/html/libxml-xmlIO.html
index 1e3b3c3..1aaf3cd 100644
--- a/doc/html/libxml-xmlIO.html
+++ b/doc/html/libxml-xmlIO.html
@@ -102,7 +102,7 @@
 </pre><p>Wrapper around xmlFileOpen_real that try it with an unescaped version of @filename, if this fails fallback to @filename</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>filename</tt></i>:</span></td><td>the URI for matching</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>a handler or NULL in case or failure</td></tr></tbody></table></div><h3><a name="xmlFileRead" id="xmlFileRead"></a>Function: xmlFileRead</h3><pre class="programlisting">int	xmlFileRead			(void * context, <br />					 char * buffer, <br />					 int len)<br />
 </pre><p>Read @len bytes to @buffer from the I/O channel.</p>
-<div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>context</tt></i>:</span></td><td>the I/O context</td></tr><tr><td><span class="term"><i><tt>buffer</tt></i>:</span></td><td>where to drop data</td></tr><tr><td><span class="term"><i><tt>len</tt></i>:</span></td><td>number of bytes to write</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the number of bytes written</td></tr></tbody></table></div><h3><a name="xmlFreeParserInputBuffer" id="xmlFreeParserInputBuffer"></a>Function: xmlFreeParserInputBuffer</h3><pre class="programlisting">void	xmlFreeParserInputBuffer	(<a href="libxml-tree.html#xmlParserInputBufferPtr">xmlParserInputBufferPtr</a> in)<br />
+<div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>context</tt></i>:</span></td><td>the I/O context</td></tr><tr><td><span class="term"><i><tt>buffer</tt></i>:</span></td><td>where to drop data</td></tr><tr><td><span class="term"><i><tt>len</tt></i>:</span></td><td>number of bytes to write</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the number of bytes written or &lt; 0 in case of failure</td></tr></tbody></table></div><h3><a name="xmlFreeParserInputBuffer" id="xmlFreeParserInputBuffer"></a>Function: xmlFreeParserInputBuffer</h3><pre class="programlisting">void	xmlFreeParserInputBuffer	(<a href="libxml-tree.html#xmlParserInputBufferPtr">xmlParserInputBufferPtr</a> in)<br />
 </pre><p>Free up the memory used by a buffered parser input</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>in</tt></i>:</span></td><td>a buffered parser input</td></tr></tbody></table></div><h3><a name="xmlIOFTPClose" id="xmlIOFTPClose"></a>Function: xmlIOFTPClose</h3><pre class="programlisting">int	xmlIOFTPClose			(void * context)<br />
 </pre><p>Close an FTP I/O channel</p>
diff --git a/doc/html/libxml-xmlstring.html b/doc/html/libxml-xmlstring.html
index 4a48826..9b29924 100644
--- a/doc/html/libxml-xmlstring.html
+++ b/doc/html/libxml-xmlstring.html
@@ -100,7 +100,7 @@
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>utf</tt></i>:</span></td><td>the input UTF8 *</td></tr><tr><td><span class="term"><i><tt>len</tt></i>:</span></td><td>the len of @utf (in chars)</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>a new UTF8 * or NULL</td></tr></tbody></table></div><h3><a name="xmlUTF8Strpos" id="xmlUTF8Strpos"></a>Function: xmlUTF8Strpos</h3><pre class="programlisting">const <a href="libxml-xmlstring.html#xmlChar">xmlChar</a> *	xmlUTF8Strpos		(const <a href="libxml-xmlstring.html#xmlChar">xmlChar</a> * utf, <br />					 int pos)<br />
 </pre><p>a function to provide the equivalent of fetching a character from a string array</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>utf</tt></i>:</span></td><td>the input UTF8 *</td></tr><tr><td><span class="term"><i><tt>pos</tt></i>:</span></td><td>the position of the desired UTF8 char (in chars)</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>a pointer to the UTF8 character or NULL</td></tr></tbody></table></div><h3><a name="xmlUTF8Strsize" id="xmlUTF8Strsize"></a>Function: xmlUTF8Strsize</h3><pre class="programlisting">int	xmlUTF8Strsize			(const <a href="libxml-xmlstring.html#xmlChar">xmlChar</a> * utf, <br />					 int len)<br />
-</pre><p>storage size of an UTF8 string</p>
+</pre><p>storage size of an UTF8 string the behaviour is not garanteed if the input string is not UTF-8</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>utf</tt></i>:</span></td><td>a sequence of UTF-8 encoded bytes</td></tr><tr><td><span class="term"><i><tt>len</tt></i>:</span></td><td>the number of <a href="libxml-SAX.html#characters">characters</a> in the array</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the storage size of the first 'len' <a href="libxml-SAX.html#characters">characters</a> of ARRAY</td></tr></tbody></table></div><h3><a name="xmlUTF8Strsub" id="xmlUTF8Strsub"></a>Function: xmlUTF8Strsub</h3><pre class="programlisting"><a href="libxml-xmlstring.html#xmlChar">xmlChar</a> *	xmlUTF8Strsub		(const <a href="libxml-xmlstring.html#xmlChar">xmlChar</a> * utf, <br />					 int start, <br />					 int len)<br />
 </pre><p>Create a substring from a given UTF-8 string Note: positions are given in units of UTF-8 chars</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>utf</tt></i>:</span></td><td>a sequence of UTF-8 encoded bytes</td></tr><tr><td><span class="term"><i><tt>start</tt></i>:</span></td><td>relative pos of first char</td></tr><tr><td><span class="term"><i><tt>len</tt></i>:</span></td><td>total number to copy</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>a pointer to a newly created string or NULL if any problem</td></tr></tbody></table></div><p><a href="../bugs.html">Daniel Veillard</a></p></td></tr></table></td></tr></table></td></tr></table></td></tr></table></td></tr></table></body></html>
diff --git a/doc/html/libxml-xmlwriter.html b/doc/html/libxml-xmlwriter.html
index 071ced6..3127a8b 100644
--- a/doc/html/libxml-xmlwriter.html
+++ b/doc/html/libxml-xmlwriter.html
@@ -100,7 +100,7 @@
 }</pre><h3><a name="xmlFreeTextWriter" id="xmlFreeTextWriter"></a>Function: xmlFreeTextWriter</h3><pre class="programlisting">void	xmlFreeTextWriter		(<a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> writer)<br />
 </pre><p>Deallocate all the resources associated to the writer</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>writer</tt></i>:</span></td><td>the <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a></td></tr></tbody></table></div><h3><a name="xmlNewTextWriter" id="xmlNewTextWriter"></a>Function: xmlNewTextWriter</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriter	(<a href="libxml-tree.html#xmlOutputBufferPtr">xmlOutputBufferPtr</a> out)<br />
-</pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure using an <a href="libxml-tree.html#xmlOutputBufferPtr">xmlOutputBufferPtr</a></p>
+</pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure using an <a href="libxml-tree.html#xmlOutputBufferPtr">xmlOutputBufferPtr</a> NOTE: the @out parameter will be deallocated when the writer is closed (if the call succeed.)</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>out</tt></i>:</span></td><td>an <a href="libxml-tree.html#xmlOutputBufferPtr">xmlOutputBufferPtr</a></td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlNewTextWriterDoc" id="xmlNewTextWriterDoc"></a>Function: xmlNewTextWriterDoc</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriterDoc	(<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> * doc, <br />						 int compression)<br />
 </pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure with @*doc as output</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>doc</tt></i>:</span></td><td>address of a <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> to hold the new XML document tree</td></tr><tr><td><span class="term"><i><tt>compression</tt></i>:</span></td><td>compress the output?</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlNewTextWriterFilename" id="xmlNewTextWriterFilename"></a>Function: xmlNewTextWriterFilename</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriterFilename	(const char * uri, <br />							 int compression)<br />
@@ -108,7 +108,7 @@
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>uri</tt></i>:</span></td><td>the URI of the resource for the output</td></tr><tr><td><span class="term"><i><tt>compression</tt></i>:</span></td><td>compress the output?</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlNewTextWriterMemory" id="xmlNewTextWriterMemory"></a>Function: xmlNewTextWriterMemory</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriterMemory	(<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, <br />						 int compression)<br />
 </pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure with @buf as output TODO: handle compression</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>buf</tt></i>:</span></td><td><a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a></td></tr><tr><td><span class="term"><i><tt>compression</tt></i>:</span></td><td>compress the output?</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlNewTextWriterPushParser" id="xmlNewTextWriterPushParser"></a>Function: xmlNewTextWriterPushParser</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriterPushParser	(<a href="libxml-tree.html#xmlParserCtxtPtr">xmlParserCtxtPtr</a> ctxt, <br />							 int compression)<br />
-</pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure with @ctxt as output TODO: handle compression</p>
+</pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure with @ctxt as output NOTE: the @ctxt context will be freed with the resulting writer (if the call succeeds). TODO: handle compression</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i>:</span></td><td><a href="libxml-tree.html#xmlParserCtxtPtr">xmlParserCtxtPtr</a> to hold the new XML document tree</td></tr><tr><td><span class="term"><i><tt>compression</tt></i>:</span></td><td>compress the output?</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlNewTextWriterTree" id="xmlNewTextWriterTree"></a>Function: xmlNewTextWriterTree</h3><pre class="programlisting"><a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a>	xmlNewTextWriterTree	(<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, <br />						 <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br />						 int compression)<br />
 </pre><p>Create a new <a href="libxml-xmlwriter.html#xmlNewTextWriter">xmlNewTextWriter</a> structure with @doc as output starting at @node</p>
 <div class="variablelist"><table border="0"><col align="left" /><tbody><tr><td><span class="term"><i><tt>doc</tt></i>:</span></td><td><a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a></td></tr><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td><a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> or NULL for doc-&gt;children</td></tr><tr><td><span class="term"><i><tt>compression</tt></i>:</span></td><td>compress the output?</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the new <a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> or NULL in case of error</td></tr></tbody></table></div><h3><a name="xmlTextWriterEndAttribute" id="xmlTextWriterEndAttribute"></a>Function: xmlTextWriterEndAttribute</h3><pre class="programlisting">int	xmlTextWriterEndAttribute	(<a href="libxml-xmlwriter.html#xmlTextWriterPtr">xmlTextWriterPtr</a> writer)<br />
diff --git a/doc/html/libxml-xpath.html b/doc/html/libxml-xpath.html
index 5594973..0fccabf 100644
--- a/doc/html/libxml-xpath.html
+++ b/doc/html/libxml-xpath.html
@@ -159,6 +159,7 @@
     <a name="XPATH_UNDEF_PREFIX_ERROR" id="XPATH_UNDEF_PREFIX_ERROR">XPATH_UNDEF_PREFIX_ERROR</a> = 19
     <a name="XPATH_ENCODING_ERROR" id="XPATH_ENCODING_ERROR">XPATH_ENCODING_ERROR</a> = 20
     <a name="XPATH_INVALID_CHAR_ERROR" id="XPATH_INVALID_CHAR_ERROR">XPATH_INVALID_CHAR_ERROR</a> = 21
+    <a name="XPATH_INVALID_CTXT" id="XPATH_INVALID_CTXT">XPATH_INVALID_CTXT</a> = 22
 }
 </pre><h3><a name="xmlXPathFunct" id="xmlXPathFunct">Structure xmlXPathFunct</a></h3><pre class="programlisting">Structure xmlXPathFunct<br />struct _xmlXPathFunct {
     const <a href="libxml-xmlstring.html#xmlChar">xmlChar</a> *	name	: the function name
diff --git a/doc/libxml2-api.xml b/doc/libxml2-api.xml
index daae1d2..6a93755 100644
--- a/doc/libxml2-api.xml
+++ b/doc/libxml2-api.xml
@@ -3182,6 +3182,7 @@
      <exports symbol='XPATH_RANGE' type='enum'/>
      <exports symbol='XPTR_SYNTAX_ERROR' type='enum'/>
      <exports symbol='XPATH_LOCATIONSET' type='enum'/>
+     <exports symbol='XPATH_INVALID_CTXT' type='enum'/>
      <exports symbol='XPATH_INVALID_CHAR_ERROR' type='enum'/>
      <exports symbol='XPATH_UNDEF_VARIABLE_ERROR' type='enum'/>
      <exports symbol='XPATH_UNCLOSED_ERROR' type='enum'/>
@@ -3196,9 +3197,9 @@
      <exports symbol='XPATH_EXPR_ERROR' type='enum'/>
      <exports symbol='XPATH_VARIABLE_REF_ERROR' type='enum'/>
      <exports symbol='XPATH_INVALID_TYPE' type='enum'/>
-     <exports symbol='XPATH_INVALID_CTXT_SIZE' type='enum'/>
-     <exports symbol='XPATH_INVALID_CTXT_POSITION' type='enum'/>
      <exports symbol='XPATH_UNDEFINED' type='enum'/>
+     <exports symbol='XPATH_INVALID_CTXT_POSITION' type='enum'/>
+     <exports symbol='XPATH_INVALID_CTXT_SIZE' type='enum'/>
      <exports symbol='XPATH_MEMORY_ERROR' type='enum'/>
      <exports symbol='XPATH_UNFINISHED_LITERAL_ERROR' type='enum'/>
      <exports symbol='XPATH_NUMBER' type='enum'/>
@@ -5256,6 +5257,7 @@
     <enum name='XPATH_EXPR_ERROR' file='xpath' value='7' type='xmlXPathError'/>
     <enum name='XPATH_INVALID_ARITY' file='xpath' value='12' type='xmlXPathError'/>
     <enum name='XPATH_INVALID_CHAR_ERROR' file='xpath' value='21' type='xmlXPathError'/>
+    <enum name='XPATH_INVALID_CTXT' file='xpath' value='22' type='xmlXPathError'/>
     <enum name='XPATH_INVALID_CTXT_POSITION' file='xpath' value='14' type='xmlXPathError'/>
     <enum name='XPATH_INVALID_CTXT_SIZE' file='xpath' value='13' type='xmlXPathError'/>
     <enum name='XPATH_INVALID_OPERAND' file='xpath' value='10' type='xmlXPathError'/>
@@ -8878,7 +8880,7 @@
     </function>
     <function name='xmlFileRead' file='xmlIO'>
       <info>Read @len bytes to @buffer from the I/O channel.</info>
-      <return type='int' info='the number of bytes written'/>
+      <return type='int' info='the number of bytes written or &lt; 0 in case of failure'/>
       <arg name='context' type='void *' info='the I/O context'/>
       <arg name='buffer' type='char *' info='where to drop data'/>
       <arg name='len' type='int' info='number of bytes to write'/>
@@ -10549,7 +10551,7 @@
     </function>
     <function name='xmlNewTextWriter' file='xmlwriter'>
       <cond>LIBXML_WRITER_ENABLED</cond>
-      <info>Create a new xmlNewTextWriter structure using an xmlOutputBufferPtr</info>
+      <info>Create a new xmlNewTextWriter structure using an xmlOutputBufferPtr NOTE: the @out parameter will be deallocated when the writer is closed (if the call succeed.)</info>
       <return type='xmlTextWriterPtr' info='the new xmlTextWriterPtr or NULL in case of error'/>
       <arg name='out' type='xmlOutputBufferPtr' info='an xmlOutputBufferPtr'/>
     </function>
@@ -10576,7 +10578,7 @@
     </function>
     <function name='xmlNewTextWriterPushParser' file='xmlwriter'>
       <cond>LIBXML_WRITER_ENABLED</cond>
-      <info>Create a new xmlNewTextWriter structure with @ctxt as output TODO: handle compression</info>
+      <info>Create a new xmlNewTextWriter structure with @ctxt as output NOTE: the @ctxt context will be freed with the resulting writer (if the call succeeds). TODO: handle compression</info>
       <return type='xmlTextWriterPtr' info='the new xmlTextWriterPtr or NULL in case of error'/>
       <arg name='ctxt' type='xmlParserCtxtPtr' info='xmlParserCtxtPtr to hold the new XML document tree'/>
       <arg name='compression' type='int' info='compress the output?'/>
@@ -12756,6 +12758,7 @@
     </function>
     <function name='xmlShell' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell This allow to load, validate, view, modify and save a document using a environment similar to a UNIX commandline.</info>
       <return type='void'/>
       <arg name='doc' type='xmlDocPtr' info='the initial document'/>
@@ -12765,6 +12768,7 @@
     </function>
     <function name='xmlShellBase' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;base&quot; dumps the current XML base of the node</info>
       <return type='int' info='0'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12774,6 +12778,7 @@
     </function>
     <function name='xmlShellCat' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;cat&quot; dumps the serialization node content (XML or HTML).</info>
       <return type='int' info='0'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12783,6 +12788,7 @@
     </function>
     <functype name='xmlShellCmd' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>This is a generic signature for the XML shell functions.</info>
       <return type='int' info='an int, negative returns indicating errors.'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='a shell context'/>
@@ -12792,6 +12798,7 @@
     </functype>
     <function name='xmlShellDir' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;dir&quot; dumps informations about the node (namespace, attributes, content).</info>
       <return type='int' info='0'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12801,6 +12808,7 @@
     </function>
     <function name='xmlShellDu' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;du&quot; show the structure of the subtree under node @tree If @tree is null, the command works on the current node.</info>
       <return type='int' info='0 or -1 in case of error'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12810,6 +12818,7 @@
     </function>
     <function name='xmlShellList' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;ls&quot; Does an Unix like listing of the given node (like a directory)</info>
       <return type='int' info='0'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12819,6 +12828,7 @@
     </function>
     <function name='xmlShellLoad' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;load&quot; loads a new document specified by the filename</info>
       <return type='int' info='0 or -1 if loading failed'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12828,12 +12838,14 @@
     </function>
     <function name='xmlShellPrintNode' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Print node to the output FILE</info>
       <return type='void'/>
       <arg name='node' type='xmlNodePtr' info='a non-null node to print to the output FILE'/>
     </function>
     <function name='xmlShellPrintXPathError' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Print the xpath error to libxml default error channel</info>
       <return type='void'/>
       <arg name='errorType' type='int' info='valid xpath error id'/>
@@ -12841,12 +12853,14 @@
     </function>
     <function name='xmlShellPrintXPathResult' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Prints result to the output FILE</info>
       <return type='void'/>
       <arg name='list' type='xmlXPathObjectPtr' info='a valid result generated by an xpath evaluation'/>
     </function>
     <function name='xmlShellPwd' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;pwd&quot; Show the full path from the root to the node, if needed building thumblers when similar elements exists at a given ancestor level. The output is compatible with XPath commands.</info>
       <return type='int' info='0 or -1 in case of error'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12856,12 +12870,14 @@
     </function>
     <functype name='xmlShellReadlineFunc' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>This is a generic signature for the XML shell input function.</info>
       <return type='char *' info='a string which will be freed by the Shell.'/>
       <arg name='prompt' type='char *' info='a string prompt'/>
     </functype>
     <function name='xmlShellSave' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <cond>LIBXML_OUTPUT_ENABLED</cond>
       <info>Implements the XML shell function &quot;save&quot; Write the current document to the filename, or it&apos;s original name</info>
       <return type='int' info='0 or -1 in case of error'/>
@@ -12872,6 +12888,7 @@
     </function>
     <function name='xmlShellValidate' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <info>Implements the XML shell function &quot;validate&quot; Validate the document, if a DTD path is provided, then the validation is done against the given DTD.</info>
       <return type='int' info='0 or -1 in case of error'/>
       <arg name='ctxt' type='xmlShellCtxtPtr' info='the shell context'/>
@@ -12881,6 +12898,7 @@
     </function>
     <function name='xmlShellWrite' file='debugXML'>
       <cond>LIBXML_DEBUG_ENABLED</cond>
+      <cond>LIBXML_XPATH_ENABLED</cond>
       <cond>LIBXML_OUTPUT_ENABLED</cond>
       <info>Implements the XML shell function &quot;write&quot; Write the current node to the filename, it saves the serialization of the subtree under the @node specified</info>
       <return type='int' info='0 or -1 in case of error'/>
@@ -15289,7 +15307,7 @@
       <arg name='pos' type='int' info='the position of the desired UTF8 char (in chars)'/>
     </function>
     <function name='xmlUTF8Strsize' file='xmlstring'>
-      <info>storage size of an UTF8 string</info>
+      <info>storage size of an UTF8 string the behaviour is not garanteed if the input string is not UTF-8</info>
       <return type='int' info='the storage size of the first &apos;len&apos; characters of ARRAY'/>
       <arg name='utf' type='const xmlChar *' info='a sequence of UTF-8 encoded bytes'/>
       <arg name='len' type='int' info='the number of characters in the array'/>
diff --git a/doc/libxml2-refs.xml b/doc/libxml2-refs.xml
index 4d0ecfb..5be0c13 100644
--- a/doc/libxml2-refs.xml
+++ b/doc/libxml2-refs.xml
@@ -1248,6 +1248,7 @@
     <reference name='XPATH_EXPR_ERROR' href='html/libxml-xpath.html#XPATH_EXPR_ERROR'/>
     <reference name='XPATH_INVALID_ARITY' href='html/libxml-xpath.html#XPATH_INVALID_ARITY'/>
     <reference name='XPATH_INVALID_CHAR_ERROR' href='html/libxml-xpath.html#XPATH_INVALID_CHAR_ERROR'/>
+    <reference name='XPATH_INVALID_CTXT' href='html/libxml-xpath.html#XPATH_INVALID_CTXT'/>
     <reference name='XPATH_INVALID_CTXT_POSITION' href='html/libxml-xpath.html#XPATH_INVALID_CTXT_POSITION'/>
     <reference name='XPATH_INVALID_CTXT_SIZE' href='html/libxml-xpath.html#XPATH_INVALID_CTXT_SIZE'/>
     <reference name='XPATH_INVALID_OPERAND' href='html/libxml-xpath.html#XPATH_INVALID_OPERAND'/>
@@ -4503,6 +4504,7 @@
       <ref name='XPATH_EXPR_ERROR'/>
       <ref name='XPATH_INVALID_ARITY'/>
       <ref name='XPATH_INVALID_CHAR_ERROR'/>
+      <ref name='XPATH_INVALID_CTXT'/>
       <ref name='XPATH_INVALID_CTXT_POSITION'/>
       <ref name='XPATH_INVALID_CTXT_SIZE'/>
       <ref name='XPATH_INVALID_OPERAND'/>
@@ -12765,6 +12767,7 @@
       <ref name='XPATH_EXPR_ERROR'/>
       <ref name='XPATH_INVALID_ARITY'/>
       <ref name='XPATH_INVALID_CHAR_ERROR'/>
+      <ref name='XPATH_INVALID_CTXT'/>
       <ref name='XPATH_INVALID_CTXT_POSITION'/>
       <ref name='XPATH_INVALID_CTXT_SIZE'/>
       <ref name='XPATH_INVALID_OPERAND'/>
@@ -15284,6 +15287,8 @@
           <ref name='xmlNewDocNode'/>
           <ref name='xmlNewDocNodeEatName'/>
           <ref name='xmlNewTextChild'/>
+          <ref name='xmlNewTextWriter'/>
+          <ref name='xmlNewTextWriterPushParser'/>
           <ref name='xmlParseExternalID'/>
           <ref name='xmlParsePEReference'/>
           <ref name='xmlParserHandlePEReference'/>
@@ -18026,6 +18031,7 @@
           <ref name='xmlNodeSetSpacePreserve'/>
           <ref name='xmlSAX2ResolveEntity'/>
           <ref name='xmlTextReaderSetParserProp'/>
+          <ref name='xmlUTF8Strsize'/>
         </word>
         <word name='below'>
           <ref name='_xmlParserCtxt'/>
@@ -18242,6 +18248,8 @@
           <ref name='xmlInitializePredefinedEntities'/>
           <ref name='xmlNanoFTPRead'/>
           <ref name='xmlNanoHTTPRead'/>
+          <ref name='xmlNewTextWriter'/>
+          <ref name='xmlNewTextWriterPushParser'/>
           <ref name='xmlParseReference'/>
           <ref name='xmlSAXUserParseFile'/>
           <ref name='xmlSAXUserParseMemory'/>
@@ -18596,6 +18604,7 @@
         </word>
         <word name='closed'>
           <ref name='xmlCtxtReadFd'/>
+          <ref name='xmlNewTextWriter'/>
           <ref name='xmlReadFd'/>
           <ref name='xmlReaderForFd'/>
           <ref name='xmlReaderNewFd'/>
@@ -19389,6 +19398,7 @@
           <ref name='xmlEncodeSpecialChars'/>
           <ref name='xmlGetFeaturesList'/>
           <ref name='xmlHashFree'/>
+          <ref name='xmlNewTextWriter'/>
           <ref name='xmlSaveUri'/>
           <ref name='xmlTextReaderConstBaseUri'/>
           <ref name='xmlTextReaderConstEncoding'/>
@@ -20728,6 +20738,7 @@
           <ref name='xmlDocDump'/>
           <ref name='xmlDocFormatDump'/>
           <ref name='xmlFileOpen'/>
+          <ref name='xmlFileRead'/>
           <ref name='xmlListAppend'/>
           <ref name='xmlListInsert'/>
           <ref name='xmlNanoHTTPFetch'/>
@@ -21164,6 +21175,9 @@
     </chunk>
     <chunk name='chunk14'>
       <letter name='g'>
+        <word name='garanteed'>
+          <ref name='xmlUTF8Strsize'/>
+        </word>
         <word name='garbage'>
           <ref name='xmlGcMemGet'/>
           <ref name='xmlGcMemSetup'/>
@@ -26560,6 +26574,9 @@
           <ref name='xmlXIncludeProcessTree'/>
           <ref name='xmlXIncludeProcessTreeFlags'/>
         </word>
+        <word name='succeed'>
+          <ref name='xmlNewTextWriter'/>
+        </word>
         <word name='succeeded'>
           <ref name='xmlHashAddEntry'/>
           <ref name='xmlHashAddEntry2'/>
@@ -26574,6 +26591,7 @@
         </word>
         <word name='succeeds'>
           <ref name='xmlCheckFilename'/>
+          <ref name='xmlNewTextWriterPushParser'/>
         </word>
         <word name='successful'>
           <ref name='xmlACatalogAdd'/>
@@ -27831,6 +27849,8 @@
         </word>
         <word name='writer'>
           <ref name='xmlFreeTextWriter'/>
+          <ref name='xmlNewTextWriter'/>
+          <ref name='xmlNewTextWriterPushParser'/>
         </word>
         <word name='writes'>
           <ref name='xmlBufferWriteQuotedString'/>
diff --git a/elfgcchack.h b/elfgcchack.h
index c72afad..3f430fe 100644
--- a/elfgcchack.h
+++ b/elfgcchack.h
@@ -4177,92 +4177,120 @@
 #define xmlSetupParserForBuffer xmlSetupParserForBuffer__internal_alias
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShell) xmlShell__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShell) xmlShell __attribute((alias("xmlShell__internal_alias")));
 #define xmlShell xmlShell__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellBase) xmlShellBase__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellBase) xmlShellBase __attribute((alias("xmlShellBase__internal_alias")));
 #define xmlShellBase xmlShellBase__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellCat) xmlShellCat__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellCat) xmlShellCat __attribute((alias("xmlShellCat__internal_alias")));
 #define xmlShellCat xmlShellCat__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellDir) xmlShellDir__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellDir) xmlShellDir __attribute((alias("xmlShellDir__internal_alias")));
 #define xmlShellDir xmlShellDir__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellDu) xmlShellDu__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellDu) xmlShellDu __attribute((alias("xmlShellDu__internal_alias")));
 #define xmlShellDu xmlShellDu__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellList) xmlShellList__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellList) xmlShellList __attribute((alias("xmlShellList__internal_alias")));
 #define xmlShellList xmlShellList__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellLoad) xmlShellLoad__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellLoad) xmlShellLoad __attribute((alias("xmlShellLoad__internal_alias")));
 #define xmlShellLoad xmlShellLoad__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellPrintNode) xmlShellPrintNode__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellPrintNode) xmlShellPrintNode __attribute((alias("xmlShellPrintNode__internal_alias")));
 #define xmlShellPrintNode xmlShellPrintNode__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellPrintXPathError) xmlShellPrintXPathError__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellPrintXPathError) xmlShellPrintXPathError __attribute((alias("xmlShellPrintXPathError__internal_alias")));
 #define xmlShellPrintXPathError xmlShellPrintXPathError__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellPrintXPathResult) xmlShellPrintXPathResult__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellPrintXPathResult) xmlShellPrintXPathResult __attribute((alias("xmlShellPrintXPathResult__internal_alias")));
 #define xmlShellPrintXPathResult xmlShellPrintXPathResult__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellPwd) xmlShellPwd__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellPwd) xmlShellPwd __attribute((alias("xmlShellPwd__internal_alias")));
 #define xmlShellPwd xmlShellPwd__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 #ifdef LIBXML_OUTPUT_ENABLED
 extern __typeof (xmlShellSave) xmlShellSave__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellSave) xmlShellSave __attribute((alias("xmlShellSave__internal_alias")));
 #define xmlShellSave xmlShellSave__internal_alias
 #endif
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 extern __typeof (xmlShellValidate) xmlShellValidate__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellValidate) xmlShellValidate __attribute((alias("xmlShellValidate__internal_alias")));
 #define xmlShellValidate xmlShellValidate__internal_alias
 #endif
+#endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 #ifdef LIBXML_OUTPUT_ENABLED
 extern __typeof (xmlShellWrite) xmlShellWrite__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlShellWrite) xmlShellWrite __attribute((alias("xmlShellWrite__internal_alias")));
 #define xmlShellWrite xmlShellWrite__internal_alias
 #endif
 #endif
+#endif
 
 extern __typeof (xmlSkipBlankChars) xmlSkipBlankChars__internal_alias __attribute((visibility("hidden")));
 extern __typeof (xmlSkipBlankChars) xmlSkipBlankChars __attribute((alias("xmlSkipBlankChars__internal_alias")));
diff --git a/gentest.py b/gentest.py
index d66b50a..8975cd9 100755
--- a/gentest.py
+++ b/gentest.py
@@ -92,6 +92,7 @@
     "xmlValidGetPotentialChildren" : "LIBXML_VALID_ENABLED",
     "xmlValidGetValidElements" : "LIBXML_VALID_ENABLED",
     "docbDefaultSAXHandlerInit" : "LIBXML_DOCB_ENABLED",
+    "xmlTextReaderPreservePattern" : "LIBXML_PATTERN_ENABLED",
 }
 
 #
@@ -775,6 +776,7 @@
     for arg in t_args:
 	test.write("    }\n")
 
+    test.write("    function_tests++;\n")
     #
     # end of conditional
     #
@@ -787,7 +789,6 @@
     nb_tests = nb_tests + 1;
 
     test.write("""
-    function_tests++;
     return(test_ret);
 }
 
@@ -816,7 +817,7 @@
 test_%s(void) {
     int test_ret = 0;
 
-    printf("Testing %s : %d of %d functions ...\\n");
+    if (quiet == 0) printf("Testing %s : %d of %d functions ...\\n");
 """ % (module, module, nb_tests - nb_tests_old, i))
 
     # iterate over all functions in the module generating the call
diff --git a/include/libxml/catalog.h b/include/libxml/catalog.h
index 2996330..b444137 100644
--- a/include/libxml/catalog.h
+++ b/include/libxml/catalog.h
@@ -21,6 +21,7 @@
 
 #include <libxml/xmlversion.h>
 #include <libxml/xmlstring.h>
+#include <libxml/tree.h>
 
 #ifdef LIBXML_CATALOG_ENABLED
 
diff --git a/include/libxml/debugXML.h b/include/libxml/debugXML.h
index d3b123c..733ccd4 100644
--- a/include/libxml/debugXML.h
+++ b/include/libxml/debugXML.h
@@ -91,6 +91,7 @@
  *								*
  ****************************************************************/
 
+#ifdef LIBXML_XPATH_ENABLED
 /**
  * xmlShellReadlineFunc:
  * @prompt:  a string prompt
@@ -204,6 +205,8 @@
 				 xmlShellReadlineFunc input,
 				 FILE *output);
 			 
+#endif /* LIBXML_XPATH_ENABLED */
+
 #ifdef __cplusplus
 }
 #endif
diff --git a/parser.c b/parser.c
index 3404177..baa9c47 100644
--- a/parser.c
+++ b/parser.c
@@ -1006,15 +1006,17 @@
 {
     if (ctxt == NULL) return(0);
     if (ctxt->nodeNr >= ctxt->nodeMax) {
-        ctxt->nodeMax *= 2;
-        ctxt->nodeTab =
-            (xmlNodePtr *) xmlRealloc(ctxt->nodeTab,
-                                      ctxt->nodeMax *
+        xmlNodePtr *tmp;
+
+	tmp = (xmlNodePtr *) xmlRealloc(ctxt->nodeTab,
+                                      ctxt->nodeMax * 2 *
                                       sizeof(ctxt->nodeTab[0]));
-        if (ctxt->nodeTab == NULL) {
+        if (tmp == NULL) {
             xmlErrMemory(ctxt, NULL);
             return (0);
         }
+        ctxt->nodeTab = tmp;
+	ctxt->nodeMax *= 2;
     }
     if (((unsigned int) ctxt->nodeNr) > xmlParserMaxDepth) {
 	xmlFatalErrMsgInt(ctxt, XML_ERR_INTERNAL_ERROR,
diff --git a/testThreads.c b/testThreads.c
index d740a14..7147182 100644
--- a/testThreads.c
+++ b/testThreads.c
@@ -2,7 +2,7 @@
 #include <stdio.h>
 #include "libxml.h"
 
-#if defined(LIBXML_THREAD_ENABLED) && defined(LIBXML_CATALOG_ENABLED)
+#if defined(LIBXML_THREAD_ENABLED) && defined(LIBXML_CATALOG_ENABLED) && defined(LIBXML_SAX1_ENABLED)
 #include <libxml/globals.h>
 #include <libxml/threads.h>
 #include <libxml/parser.h>
diff --git a/testapi.c b/testapi.c
index 610e8fc..22c845d 100644
--- a/testapi.c
+++ b/testapi.c
@@ -111,6 +111,8 @@
     return(api_attr);
 }
 
+static int quiet = 0;
+
 int main(int argc, char **argv) {
     int ret;
     int blocks, mem;
@@ -129,9 +131,17 @@
 
     xmlSetStructuredErrorFunc(NULL, structured_errors);
 
-    if (argc == 2)
-        ret = test_module(argv[1]);
-    else
+    if (argc >= 2) {
+        if (!strcmp(argv[1], "-q")) {
+	    quiet = 1;
+	    if (argc >= 3)
+	        ret = test_module(argv[2]);
+	    else
+		ret = testlibxml2();
+        } else {
+	   ret = test_module(argv[1]);
+	}
+    } else
 	ret = testlibxml2();
 
     xmlCleanupParser();
@@ -289,7 +299,7 @@
 static double gen_double(int no, int nr ATTRIBUTE_UNUSED) {
     if (no == 0) return(0);
     if (no == 1) return(-1.1);
-#if defined(LIBXML_SCHEMAS_ENABLED) || defined(LIBXML_XPATH_ENABLED)
+#if defined(LIBXML_XPATH_ENABLED)
     if (no == 2) return(xmlXPathNAN);
 #endif
     return(-1);
@@ -857,6 +867,7 @@
 #endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 #define gen_nb_xmlShellCtxtPtr 1
 static xmlShellCtxtPtr gen_xmlShellCtxtPtr(int no ATTRIBUTE_UNUSED, int nr ATTRIBUTE_UNUSED) {
     return(NULL);
@@ -864,6 +875,7 @@
 static void des_xmlShellCtxtPtr(int no ATTRIBUTE_UNUSED, xmlShellCtxtPtr val ATTRIBUTE_UNUSED, int nr ATTRIBUTE_UNUSED) {
 }
 #endif
+#endif
 
 #ifdef LIBXML_PATTERN_ENABLED
 #define gen_nb_xmlPatternPtr 1
@@ -1548,9 +1560,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1606,9 +1618,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1664,9 +1676,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1705,9 +1717,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1785,10 +1797,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1848,9 +1860,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1903,9 +1915,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -1972,9 +1984,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2004,9 +2016,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2045,9 +2057,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2086,9 +2098,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2127,9 +2139,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2189,9 +2201,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2223,9 +2235,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2257,9 +2269,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2291,9 +2303,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2332,9 +2344,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2366,9 +2378,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2407,9 +2419,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2441,9 +2453,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2498,10 +2510,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2540,9 +2552,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2575,9 +2587,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2607,9 +2619,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2648,9 +2660,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2679,9 +2691,9 @@
         xmlResetLastError();
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2734,9 +2746,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2782,9 +2794,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2844,9 +2856,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2899,9 +2911,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2954,9 +2966,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -2974,7 +2986,7 @@
 test_HTMLparser(void) {
     int test_ret = 0;
 
-    printf("Testing HTMLparser : 31 of 37 functions ...\n");
+    if (quiet == 0) printf("Testing HTMLparser : 31 of 37 functions ...\n");
     test_ret += test_UTF8ToHtml();
     test_ret += test_htmlAttrAllowed();
     test_ret += test_htmlAutoCloseTag();
@@ -3060,10 +3072,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3108,10 +3120,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3151,10 +3163,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3206,10 +3218,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3241,9 +3253,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3275,9 +3287,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3316,9 +3328,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3357,9 +3369,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3406,10 +3418,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3454,10 +3466,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3518,10 +3530,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3580,10 +3592,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3635,10 +3647,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3678,10 +3690,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3728,10 +3740,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3785,10 +3797,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3827,9 +3839,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3837,7 +3849,7 @@
 test_HTMLtree(void) {
     int test_ret = 0;
 
-    printf("Testing HTMLtree : 17 of 17 functions ...\n");
+    if (quiet == 0) printf("Testing HTMLtree : 17 of 17 functions ...\n");
     test_ret += test_htmlDocContentDumpFormatOutput();
     test_ret += test_htmlDocContentDumpOutput();
     test_ret += test_htmlDocDump();
@@ -3879,9 +3891,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3904,9 +3916,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -3928,8 +3940,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4007,8 +4019,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4051,8 +4063,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4095,8 +4107,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4132,8 +4144,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4190,8 +4202,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4220,8 +4232,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4258,9 +4270,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -4310,8 +4322,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4375,8 +4387,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4426,8 +4438,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4458,8 +4470,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4497,8 +4509,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4529,8 +4541,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4568,8 +4580,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4600,8 +4612,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4632,8 +4644,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4664,8 +4676,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4696,8 +4708,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4740,8 +4752,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4784,8 +4796,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4815,9 +4827,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -4847,9 +4859,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -4899,8 +4911,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4931,8 +4943,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -4982,8 +4994,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5026,8 +5038,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5063,8 +5075,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5109,8 +5121,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5153,8 +5165,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5183,8 +5195,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5228,9 +5240,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5315,8 +5327,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5373,8 +5385,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5406,9 +5418,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5446,8 +5458,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -5455,7 +5467,7 @@
 test_SAX2(void) {
     int test_ret = 0;
 
-    printf("Testing SAX2 : 38 of 38 functions ...\n");
+    if (quiet == 0) printf("Testing SAX2 : 38 of 38 functions ...\n");
     test_ret += test_docbDefaultSAXHandlerInit();
     test_ret += test_htmlDefaultSAXHandlerInit();
     test_ret += test_xmlDefaultSAXHandlerInit();
@@ -5563,10 +5575,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5641,10 +5653,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5712,10 +5724,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5733,7 +5745,7 @@
 test_c14n(void) {
     int test_ret = 0;
 
-    printf("Testing c14n : 3 of 4 functions ...\n");
+    if (quiet == 0) printf("Testing c14n : 3 of 4 functions ...\n");
     test_ret += test_xmlC14NDocDumpMemory();
     test_ret += test_xmlC14NDocSave();
     test_ret += test_xmlC14NDocSaveTo();
@@ -5802,9 +5814,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5842,10 +5854,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5884,9 +5896,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5932,9 +5944,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -5973,9 +5985,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6014,9 +6026,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6055,9 +6067,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6103,9 +6115,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6120,9 +6132,9 @@
         xmlCatalogCleanup();
         call_tests++;
         xmlResetLastError();
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6139,9 +6151,9 @@
         desret_int(ret_val);
         call_tests++;
         xmlResetLastError();
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6172,10 +6184,10 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6200,9 +6212,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6234,9 +6246,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6282,9 +6294,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6323,9 +6335,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6348,9 +6360,9 @@
         des_const_xmlChar_ptr(n_value, value, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6389,9 +6401,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6423,9 +6435,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6457,9 +6469,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6491,9 +6503,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6525,9 +6537,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6557,9 +6569,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6591,9 +6603,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6616,9 +6628,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6651,9 +6663,9 @@
         des_filepath(n_filename, filename, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6674,9 +6686,9 @@
         des_const_char_ptr(n_pathss, pathss, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6728,9 +6740,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -6738,7 +6750,7 @@
 test_catalog(void) {
     int test_ret = 0;
 
-    printf("Testing catalog : 27 of 36 functions ...\n");
+    if (quiet == 0) printf("Testing catalog : 27 of 36 functions ...\n");
     test_ret += test_xmlACatalogAdd();
     test_ret += test_xmlACatalogDump();
     test_ret += test_xmlACatalogRemove();
@@ -6815,8 +6827,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -6847,8 +6859,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -6879,8 +6891,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -6911,8 +6923,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -6943,8 +6955,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -6975,8 +6987,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -7007,8 +7019,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -7039,8 +7051,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -7071,8 +7083,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -7080,7 +7092,7 @@
 test_chvalid(void) {
     int test_ret = 0;
 
-    printf("Testing chvalid : 9 of 9 functions ...\n");
+    if (quiet == 0) printf("Testing chvalid : 9 of 9 functions ...\n");
     test_ret += test_xmlCharInRange();
     test_ret += test_xmlIsBaseChar();
     test_ret += test_xmlIsBlank();
@@ -7123,9 +7135,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7164,9 +7176,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7210,9 +7222,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7256,9 +7268,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7295,9 +7307,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7334,9 +7346,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7373,9 +7385,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7412,9 +7424,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7458,9 +7470,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7504,9 +7516,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7550,9 +7562,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7589,9 +7601,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7623,9 +7635,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7662,9 +7674,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7691,6 +7703,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -7734,9 +7747,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7746,6 +7760,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -7789,9 +7804,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7801,6 +7817,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -7844,9 +7861,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7856,6 +7874,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -7899,9 +7918,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7911,6 +7931,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -7954,9 +7975,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -7966,6 +7988,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -8009,9 +8032,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8021,6 +8045,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     xmlXPathObjectPtr list; /* a valid result generated by an xpath evaluation */
     int n_list;
@@ -8041,9 +8066,10 @@
             printf("\n");
         }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8053,6 +8079,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -8096,9 +8123,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8108,6 +8136,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 #ifdef LIBXML_OUTPUT_ENABLED
     int mem_base;
     int ret_val;
@@ -8152,10 +8181,11 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8165,6 +8195,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     int mem_base;
     int ret_val;
     xmlShellCtxtPtr ctxt; /* the shell context */
@@ -8208,9 +8239,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8220,6 +8252,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 #ifdef LIBXML_OUTPUT_ENABLED
     int mem_base;
     int ret_val;
@@ -8264,10 +8297,11 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8275,7 +8309,7 @@
 test_debugXML(void) {
     int test_ret = 0;
 
-    printf("Testing debugXML : 25 of 28 functions ...\n");
+    if (quiet == 0) printf("Testing debugXML : 25 of 28 functions ...\n");
     test_ret += test_xmlBoolToText();
     test_ret += test_xmlDebugCheckDocument();
     test_ret += test_xmlDebugDumpAttr();
@@ -8327,8 +8361,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8359,8 +8393,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8405,8 +8439,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8444,8 +8478,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8490,8 +8524,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8523,8 +8557,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8555,8 +8589,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8564,7 +8598,7 @@
 test_dict(void) {
     int test_ret = 0;
 
-    printf("Testing dict : 7 of 8 functions ...\n");
+    if (quiet == 0) printf("Testing dict : 7 of 8 functions ...\n");
     test_ret += test_xmlDictCreate();
     test_ret += test_xmlDictCreateSub();
     test_ret += test_xmlDictLookup();
@@ -8626,9 +8660,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -8680,8 +8714,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8709,8 +8743,8 @@
         xmlResetLastError();
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8748,8 +8782,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8794,8 +8828,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8840,8 +8874,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8886,8 +8920,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8901,8 +8935,8 @@
         xmlCleanupCharEncodingHandlers();
         call_tests++;
         xmlResetLastError();
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8924,8 +8958,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8956,8 +8990,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -8995,8 +9029,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9047,8 +9081,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9079,8 +9113,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9094,8 +9128,8 @@
         xmlInitCharEncodingHandlers();
         call_tests++;
         xmlResetLastError();
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9136,8 +9170,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9173,8 +9207,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9182,7 +9216,7 @@
 test_encoding(void) {
     int test_ret = 0;
 
-    printf("Testing encoding : 16 of 19 functions ...\n");
+    if (quiet == 0) printf("Testing encoding : 16 of 19 functions ...\n");
     test_ret += test_UTF8Toisolat1();
     test_ret += test_isolat1ToUTF8();
     test_ret += test_xmlAddEncodingAlias();
@@ -9269,8 +9303,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9336,8 +9370,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9360,9 +9394,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -9426,9 +9460,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -9472,9 +9506,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -9512,8 +9546,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9551,8 +9585,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9590,8 +9624,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9629,8 +9663,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9668,8 +9702,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9700,8 +9734,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9724,9 +9758,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -9734,7 +9768,7 @@
 test_entities(void) {
     int test_ret = 0;
 
-    printf("Testing entities : 12 of 16 functions ...\n");
+    if (quiet == 0) printf("Testing entities : 12 of 16 functions ...\n");
     test_ret += test_xmlAddDocEntity();
     test_ret += test_xmlAddDtdEntity();
     test_ret += test_xmlCleanupPredefinedEntities();
@@ -9795,8 +9829,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9848,8 +9882,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9908,8 +9942,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -9967,8 +10001,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10013,8 +10047,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10066,8 +10100,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10112,8 +10146,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10172,8 +10206,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10246,8 +10280,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10292,8 +10326,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10345,8 +10379,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10405,8 +10439,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10477,8 +10511,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10530,8 +10564,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10590,8 +10624,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10657,8 +10691,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10666,7 +10700,7 @@
 test_hash(void) {
     int test_ret = 0;
 
-    printf("Testing hash : 16 of 23 functions ...\n");
+    if (quiet == 0) printf("Testing hash : 16 of 23 functions ...\n");
     test_ret += test_xmlHashAddEntry();
     test_ret += test_xmlHashAddEntry2();
     test_ret += test_xmlHashAddEntry3();
@@ -10728,8 +10762,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10767,8 +10801,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10797,8 +10831,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10843,8 +10877,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10895,8 +10929,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10954,8 +10988,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -10991,8 +11025,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11021,8 +11055,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11051,8 +11085,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11090,8 +11124,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11129,8 +11163,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11168,8 +11202,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11207,8 +11241,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11246,8 +11280,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11276,8 +11310,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11315,8 +11349,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11364,8 +11398,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11396,8 +11430,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11426,8 +11460,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -11445,7 +11479,7 @@
 test_list(void) {
     int test_ret = 0;
 
-    printf("Testing list : 19 of 26 functions ...\n");
+    if (quiet == 0) printf("Testing list : 19 of 26 functions ...\n");
     test_ret += test_xmlLinkGetData();
     test_ret += test_xmlListAppend();
     test_ret += test_xmlListClear();
@@ -11504,9 +11538,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11529,9 +11563,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11563,9 +11597,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11604,9 +11638,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11645,9 +11679,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11689,9 +11723,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11723,9 +11757,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11764,9 +11798,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11789,9 +11823,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11843,9 +11877,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11890,9 +11924,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11924,9 +11958,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11972,9 +12006,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -11995,9 +12029,9 @@
         des_filepath(n_URL, URL, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12036,9 +12070,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12046,7 +12080,7 @@
 test_nanoftp(void) {
     int test_ret = 0;
 
-    printf("Testing nanoftp : 15 of 22 functions ...\n");
+    if (quiet == 0) printf("Testing nanoftp : 15 of 22 functions ...\n");
     test_ret += test_xmlNanoFTPCheckResponse();
     test_ret += test_xmlNanoFTPCleanup();
     test_ret += test_xmlNanoFTPCloseConnection();
@@ -12098,9 +12132,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12123,9 +12157,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12155,9 +12189,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12189,9 +12223,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12223,9 +12257,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12278,9 +12312,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12303,9 +12337,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12372,9 +12406,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12448,9 +12482,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12482,9 +12516,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12523,9 +12557,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12571,9 +12605,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12619,9 +12653,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12663,9 +12697,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12705,10 +12739,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12729,9 +12763,9 @@
         des_filepath(n_URL, URL, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -12739,7 +12773,7 @@
 test_nanohttp(void) {
     int test_ret = 0;
 
-    printf("Testing nanohttp : 16 of 17 functions ...\n");
+    if (quiet == 0) printf("Testing nanohttp : 16 of 17 functions ...\n");
     test_ret += test_xmlNanoHTTPAuthHeader();
     test_ret += test_xmlNanoHTTPCleanup();
     test_ret += test_xmlNanoHTTPClose();
@@ -12789,8 +12823,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -12826,8 +12860,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -12856,8 +12890,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -12888,8 +12922,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -12949,9 +12983,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13010,8 +13044,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13063,8 +13097,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13130,8 +13164,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13160,8 +13194,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13220,8 +13254,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13259,8 +13293,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13316,9 +13350,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13364,9 +13398,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13413,9 +13447,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13444,8 +13478,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13467,8 +13501,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13499,8 +13533,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13531,8 +13565,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13563,8 +13597,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13609,8 +13643,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13656,8 +13690,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13681,8 +13715,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13761,9 +13795,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13842,9 +13876,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13898,9 +13932,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -13952,8 +13986,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -13992,9 +14026,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14026,9 +14060,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14060,8 +14094,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14093,9 +14127,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14127,8 +14161,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14202,9 +14236,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14236,9 +14270,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14297,8 +14331,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14337,9 +14371,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14382,8 +14416,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14469,8 +14503,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14508,8 +14542,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14540,8 +14574,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14593,8 +14627,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14639,8 +14673,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14699,8 +14733,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -14732,9 +14766,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14766,9 +14800,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14807,9 +14841,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14855,9 +14889,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14903,9 +14937,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14944,9 +14978,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -14992,9 +15026,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15047,9 +15081,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15102,9 +15136,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15164,9 +15198,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15217,9 +15251,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15277,9 +15311,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15335,9 +15369,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15381,9 +15415,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15413,9 +15447,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15446,8 +15480,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15455,7 +15489,7 @@
 test_parser(void) {
     int test_ret = 0;
 
-    printf("Testing parser : 58 of 69 functions ...\n");
+    if (quiet == 0) printf("Testing parser : 58 of 69 functions ...\n");
     test_ret += test_xmlByteConsumed();
     test_ret += test_xmlClearNodeInfoSeq();
     test_ret += test_xmlClearParserCtxt();
@@ -15558,9 +15592,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15583,9 +15617,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -15616,8 +15650,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15655,8 +15689,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15687,8 +15721,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15726,8 +15760,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15758,8 +15792,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15797,8 +15831,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15829,8 +15863,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15875,8 +15909,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15914,8 +15948,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15960,8 +15994,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -15992,8 +16026,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16031,8 +16065,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16070,8 +16104,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16109,8 +16143,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16146,8 +16180,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16178,8 +16212,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16217,8 +16251,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16256,8 +16290,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16288,8 +16322,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16327,8 +16361,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16357,8 +16391,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16387,8 +16421,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16419,8 +16453,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16456,8 +16490,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16512,8 +16546,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16558,8 +16592,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16625,8 +16659,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16699,8 +16733,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16738,8 +16772,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16784,8 +16818,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16823,8 +16857,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -16832,7 +16866,7 @@
 test_parserInternals(void) {
     int test_ret = 0;
 
-    printf("Testing parserInternals : 33 of 90 functions ...\n");
+    if (quiet == 0) printf("Testing parserInternals : 33 of 90 functions ...\n");
     test_ret += test_htmlCreateFileParserCtxt();
     test_ret += test_htmlInitAutoClose();
     test_ret += test_inputPop();
@@ -16907,9 +16941,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -16927,7 +16961,7 @@
 test_pattern(void) {
     int test_ret = 0;
 
-    printf("Testing pattern : 1 of 4 functions ...\n");
+    if (quiet == 0) printf("Testing pattern : 1 of 4 functions ...\n");
     test_ret += test_xmlPatternMatch();
     test_ret += test_xmlPatterncompile();
 
@@ -16979,10 +17013,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17020,10 +17054,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17116,9 +17150,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17181,9 +17215,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17208,9 +17242,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17242,9 +17276,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17283,9 +17317,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17317,9 +17351,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17398,9 +17432,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17446,9 +17480,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17494,9 +17528,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17542,9 +17576,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17590,9 +17624,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17631,9 +17665,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17641,7 +17675,7 @@
 test_relaxng(void) {
     int test_ret = 0;
 
-    printf("Testing relaxng : 14 of 22 functions ...\n");
+    if (quiet == 0) printf("Testing relaxng : 14 of 22 functions ...\n");
     test_ret += test_xmlRelaxNGDump();
     test_ret += test_xmlRelaxNGDumpTree();
     test_ret += test_xmlRelaxNGGetParserErrors();
@@ -17669,7 +17703,7 @@
 test_schemasInternals(void) {
     int test_ret = 0;
 
-    printf("Testing schemasInternals : 0 of 2 functions ...\n");
+    if (quiet == 0) printf("Testing schemasInternals : 0 of 2 functions ...\n");
 
     if (test_ret != 0)
 	printf("Module schemasInternals: %d errors\n", test_ret);
@@ -17710,8 +17744,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -17750,8 +17784,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -17790,8 +17824,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -17831,9 +17865,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17872,8 +17906,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -17924,9 +17958,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -17971,8 +18005,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18017,8 +18051,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18056,8 +18090,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18095,8 +18129,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18134,8 +18168,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18159,8 +18193,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18209,8 +18243,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18248,8 +18282,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18280,8 +18314,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18319,8 +18353,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18356,8 +18390,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18395,8 +18429,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18432,8 +18466,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18469,8 +18503,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18506,8 +18540,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18563,8 +18597,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18603,9 +18637,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -18637,9 +18671,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -18671,8 +18705,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18704,8 +18738,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18743,8 +18777,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18775,8 +18809,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18814,8 +18848,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18853,8 +18887,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18906,8 +18940,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18952,8 +18986,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -18991,8 +19025,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19031,9 +19065,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19084,9 +19118,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19144,9 +19178,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19190,9 +19224,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19243,9 +19277,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19291,9 +19325,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19324,8 +19358,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19365,9 +19399,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19411,9 +19445,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19437,8 +19471,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19462,8 +19496,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19494,8 +19528,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19526,8 +19560,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19558,8 +19592,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19590,8 +19624,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19629,8 +19663,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19662,9 +19696,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -19719,8 +19753,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19758,8 +19792,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19804,8 +19838,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19843,8 +19877,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19875,8 +19909,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19914,8 +19948,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19960,8 +19994,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -19999,8 +20033,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20053,9 +20087,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -20086,8 +20120,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20118,8 +20152,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20157,8 +20191,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20190,9 +20224,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -20244,8 +20278,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20297,8 +20331,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20343,8 +20377,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20389,8 +20423,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20443,9 +20477,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -20483,8 +20517,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20529,8 +20563,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20582,8 +20616,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20621,8 +20655,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20660,8 +20694,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20707,8 +20741,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20760,8 +20794,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20813,8 +20847,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20852,8 +20886,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20899,9 +20933,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -20939,8 +20973,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -20971,8 +21005,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21025,9 +21059,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21065,8 +21099,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21102,8 +21136,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21146,8 +21180,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21185,8 +21219,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21246,9 +21280,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21313,9 +21347,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21353,8 +21387,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21385,8 +21419,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21417,8 +21451,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21449,8 +21483,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21481,8 +21515,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21528,9 +21562,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21575,8 +21609,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21613,9 +21647,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21651,8 +21685,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -21696,9 +21730,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21735,9 +21769,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21774,9 +21808,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21813,9 +21847,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21854,9 +21888,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21889,9 +21923,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21937,9 +21971,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -21978,9 +22012,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22026,9 +22060,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22075,9 +22109,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22123,9 +22157,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22178,9 +22212,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22234,9 +22268,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22281,8 +22315,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22327,8 +22361,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22357,8 +22391,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22387,8 +22421,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22424,8 +22458,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22461,8 +22495,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22515,9 +22549,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22563,9 +22597,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22603,8 +22637,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22642,8 +22676,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22681,8 +22715,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22727,8 +22761,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22773,8 +22807,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22815,8 +22849,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -22862,9 +22896,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22903,9 +22937,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22944,9 +22978,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -22985,9 +23019,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -23026,9 +23060,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -23067,9 +23101,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -23077,7 +23111,7 @@
 test_tree(void) {
     int test_ret = 0;
 
-    printf("Testing tree : 129 of 146 functions ...\n");
+    if (quiet == 0) printf("Testing tree : 129 of 146 functions ...\n");
     test_ret += test_xmlAddChild();
     test_ret += test_xmlAddChildList();
     test_ret += test_xmlAddNextSibling();
@@ -23249,8 +23283,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23288,8 +23322,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23320,8 +23354,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23362,8 +23396,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23418,8 +23452,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23455,8 +23489,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23487,8 +23521,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23519,8 +23553,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23558,8 +23592,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23577,7 +23611,7 @@
 test_uri(void) {
     int test_ret = 0;
 
-    printf("Testing uri : 9 of 13 functions ...\n");
+    if (quiet == 0) printf("Testing uri : 9 of 13 functions ...\n");
     test_ret += test_xmlBuildRelativeURI();
     test_ret += test_xmlBuildURI();
     test_ret += test_xmlCanonicPath();
@@ -23678,8 +23712,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23738,8 +23772,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -23894,9 +23928,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -23933,9 +23967,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -23979,9 +24013,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24018,9 +24052,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24064,9 +24098,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24103,9 +24137,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24150,8 +24184,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24189,8 +24223,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24252,8 +24286,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24298,8 +24332,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24337,8 +24371,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24393,8 +24427,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24432,8 +24466,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24478,8 +24512,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24537,8 +24571,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24576,8 +24610,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24627,8 +24661,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -24672,9 +24706,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24713,9 +24747,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24775,9 +24809,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24837,9 +24871,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24892,9 +24926,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24947,9 +24981,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -24995,9 +25029,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25036,9 +25070,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25077,9 +25111,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25118,9 +25152,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25166,9 +25200,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25207,9 +25241,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25255,9 +25289,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25303,9 +25337,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25337,9 +25371,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25371,9 +25405,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25405,9 +25439,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25439,9 +25473,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25487,9 +25521,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25535,9 +25569,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25597,9 +25631,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25645,9 +25679,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25714,9 +25748,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25769,9 +25803,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25817,9 +25851,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25872,9 +25906,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25913,9 +25947,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -25923,7 +25957,7 @@
 test_valid(void) {
     int test_ret = 0;
 
-    printf("Testing valid : 46 of 67 functions ...\n");
+    if (quiet == 0) printf("Testing valid : 46 of 67 functions ...\n");
     test_ret += test_xmlAddAttributeDecl();
     test_ret += test_xmlAddElementDecl();
     test_ret += test_xmlAddID();
@@ -26026,9 +26060,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26067,9 +26101,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26118,9 +26152,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26152,9 +26186,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26193,9 +26227,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26234,9 +26268,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26244,7 +26278,7 @@
 test_xinclude(void) {
     int test_ret = 0;
 
-    printf("Testing xinclude : 6 of 8 functions ...\n");
+    if (quiet == 0) printf("Testing xinclude : 6 of 8 functions ...\n");
     test_ret += test_xmlXIncludeNewContext();
     test_ret += test_xmlXIncludeProcess();
     test_ret += test_xmlXIncludeProcessFlags();
@@ -26285,9 +26319,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26318,8 +26352,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26350,8 +26384,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26389,8 +26423,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26412,8 +26446,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26436,9 +26470,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26469,8 +26503,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26501,8 +26535,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26533,8 +26567,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26579,8 +26613,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26612,9 +26646,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26646,9 +26680,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26680,9 +26714,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26728,9 +26762,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26762,9 +26796,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26796,9 +26830,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26830,9 +26864,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26888,9 +26922,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -26935,8 +26969,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -26967,8 +27001,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27007,9 +27041,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27048,9 +27082,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27096,9 +27130,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27130,9 +27164,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27178,9 +27212,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27229,9 +27263,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27280,8 +27314,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27319,8 +27353,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27358,8 +27392,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27404,8 +27438,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27450,8 +27484,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27489,8 +27523,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27535,8 +27569,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27574,8 +27608,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27599,8 +27633,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27622,8 +27656,8 @@
 	    test_ret++;
             printf("\n");
         }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -27646,9 +27680,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27671,9 +27705,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27681,7 +27715,7 @@
 test_xmlIO(void) {
     int test_ret = 0;
 
-    printf("Testing xmlIO : 38 of 47 functions ...\n");
+    if (quiet == 0) printf("Testing xmlIO : 38 of 47 functions ...\n");
     test_ret += test_xmlAllocOutputBuffer();
     test_ret += test_xmlAllocParserInputBuffer();
     test_ret += test_xmlCheckFilename();
@@ -27786,9 +27820,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27884,9 +27918,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -27995,9 +28029,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28015,7 +28049,7 @@
 test_xmlautomata(void) {
     int test_ret = 0;
 
-    printf("Testing xmlautomata : 3 of 18 functions ...\n");
+    if (quiet == 0) printf("Testing xmlautomata : 3 of 18 functions ...\n");
     test_ret += test_xmlAutomataCompile();
     test_ret += test_xmlAutomataGetInitState();
     test_ret += test_xmlAutomataIsDeterminist();
@@ -28070,8 +28104,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28116,8 +28150,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28156,8 +28190,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28206,8 +28240,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28236,8 +28270,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28296,8 +28330,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28311,8 +28345,8 @@
         xmlResetLastError();
         call_tests++;
         xmlResetLastError();
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -28340,7 +28374,7 @@
 test_xmlerror(void) {
     int test_ret = 0;
 
-    printf("Testing xmlerror : 7 of 15 functions ...\n");
+    if (quiet == 0) printf("Testing xmlerror : 7 of 15 functions ...\n");
     test_ret += test_initGenericErrorDefaultFunc();
     test_ret += test_xmlCopyError();
     test_ret += test_xmlCtxtGetLastError();
@@ -28396,9 +28430,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28430,9 +28464,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28485,9 +28519,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28533,9 +28567,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28595,9 +28629,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28657,9 +28691,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28712,9 +28746,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28781,9 +28815,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28822,9 +28856,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28856,9 +28890,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28890,9 +28924,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28924,9 +28958,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28958,9 +28992,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -28992,9 +29026,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29026,9 +29060,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29060,9 +29094,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29094,9 +29128,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29128,9 +29162,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29162,9 +29196,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29203,9 +29237,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29237,9 +29271,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29271,9 +29305,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29305,9 +29339,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29339,9 +29373,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29373,9 +29407,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29407,9 +29441,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29441,9 +29475,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29482,9 +29516,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29523,9 +29557,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29571,9 +29605,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29627,9 +29661,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29668,9 +29702,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29702,9 +29736,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29736,9 +29770,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29770,9 +29804,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29804,9 +29838,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29838,9 +29872,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29872,9 +29906,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29906,9 +29940,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29940,9 +29974,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -29984,9 +30018,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30018,9 +30052,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30059,9 +30093,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30100,9 +30134,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30141,9 +30175,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30189,9 +30223,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30223,9 +30257,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30257,9 +30291,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30291,9 +30325,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30325,9 +30359,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30359,9 +30393,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30393,9 +30427,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30427,9 +30461,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30461,9 +30495,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30495,9 +30529,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30529,9 +30563,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30563,9 +30597,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30575,6 +30609,7 @@
     int test_ret = 0;
 
 #ifdef LIBXML_READER_ENABLED
+#ifdef LIBXML_PATTERN_ENABLED
     int mem_base;
     int ret_val;
     xmlTextReaderPtr reader; /* the xmlTextReaderPtr used */
@@ -30611,9 +30646,10 @@
     }
     }
     }
+    function_tests++;
+#endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30645,9 +30681,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30679,9 +30715,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30713,9 +30749,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30747,9 +30783,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30789,10 +30825,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30832,10 +30868,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30891,9 +30927,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30935,9 +30971,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -30969,9 +31005,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31003,9 +31039,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31013,7 +31049,7 @@
 test_xmlreader(void) {
     int test_ret = 0;
 
-    printf("Testing xmlreader : 68 of 78 functions ...\n");
+    if (quiet == 0) printf("Testing xmlreader : 68 of 78 functions ...\n");
     test_ret += test_xmlNewTextReader();
     test_ret += test_xmlNewTextReaderFilename();
     test_ret += test_xmlReaderForDoc();
@@ -31141,9 +31177,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31196,9 +31232,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31267,9 +31303,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31301,9 +31337,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31340,9 +31376,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31350,7 +31386,7 @@
 test_xmlregexp(void) {
     int test_ret = 0;
 
-    printf("Testing xmlregexp : 5 of 9 functions ...\n");
+    if (quiet == 0) printf("Testing xmlregexp : 5 of 9 functions ...\n");
     test_ret += test_xmlRegExecPushString();
     test_ret += test_xmlRegExecPushString2();
     test_ret += test_xmlRegNewExecCtxt();
@@ -31401,9 +31437,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31442,9 +31478,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31476,9 +31512,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31557,9 +31593,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31567,7 +31603,7 @@
 test_xmlsave(void) {
     int test_ret = 0;
 
-    printf("Testing xmlsave : 4 of 9 functions ...\n");
+    if (quiet == 0) printf("Testing xmlsave : 4 of 9 functions ...\n");
     test_ret += test_xmlSaveClose();
     test_ret += test_xmlSaveDoc();
     test_ret += test_xmlSaveFlush();
@@ -31625,10 +31661,10 @@
         }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31711,9 +31747,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31776,9 +31812,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31810,9 +31846,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31851,9 +31887,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31885,9 +31921,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -31966,9 +32002,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32000,9 +32036,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32041,9 +32077,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32082,9 +32118,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32144,9 +32180,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32154,7 +32190,7 @@
 test_xmlschemas(void) {
     int test_ret = 0;
 
-    printf("Testing xmlschemas : 11 of 18 functions ...\n");
+    if (quiet == 0) printf("Testing xmlschemas : 11 of 18 functions ...\n");
     test_ret += test_xmlSchemaDump();
     test_ret += test_xmlSchemaGetParserErrors();
     test_ret += test_xmlSchemaGetValidErrors();
@@ -32244,9 +32280,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32269,9 +32305,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32303,9 +32339,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32354,9 +32390,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32388,9 +32424,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32413,9 +32449,9 @@
         des_xmlSchemaValType(n_type, type, 0);
         xmlResetLastError();
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32464,9 +32500,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32481,9 +32517,9 @@
         xmlSchemaInitTypes();
         call_tests++;
         xmlResetLastError();
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32522,9 +32558,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32597,9 +32633,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32652,9 +32688,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32707,9 +32743,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32769,9 +32805,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32824,9 +32860,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32872,9 +32908,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -32882,7 +32918,7 @@
 test_xmlschemastypes(void) {
     int test_ret = 0;
 
-    printf("Testing xmlschemastypes : 15 of 19 functions ...\n");
+    if (quiet == 0) printf("Testing xmlschemastypes : 15 of 19 functions ...\n");
     test_ret += test_xmlSchemaCheckFacet();
     test_ret += test_xmlSchemaCleanupTypes();
     test_ret += test_xmlSchemaCollapseString();
@@ -32932,8 +32968,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -32971,8 +33007,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33003,8 +33039,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33042,8 +33078,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33081,8 +33117,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33137,8 +33173,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33186,8 +33222,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33225,8 +33261,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33264,8 +33300,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33303,8 +33339,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33335,8 +33371,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33367,8 +33403,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33413,8 +33449,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33459,8 +33495,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33505,8 +33541,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33544,8 +33580,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33583,8 +33619,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33629,8 +33665,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33668,8 +33704,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33700,8 +33736,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33732,8 +33768,8 @@
             printf("\n");
         }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33771,8 +33807,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33810,8 +33846,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33849,8 +33885,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33888,8 +33924,8 @@
         }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33934,8 +33970,8 @@
     }
     }
     }
-
     function_tests++;
+
     return(test_ret);
 }
 
@@ -33943,7 +33979,7 @@
 test_xmlstring(void) {
     int test_ret = 0;
 
-    printf("Testing xmlstring : 26 of 30 functions ...\n");
+    if (quiet == 0) printf("Testing xmlstring : 26 of 30 functions ...\n");
     test_ret += test_xmlCharStrdup();
     test_ret += test_xmlCharStrndup();
     test_ret += test_xmlCheckUTF8();
@@ -34005,9 +34041,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34039,9 +34075,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34073,9 +34109,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34107,9 +34143,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34141,9 +34177,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34175,9 +34211,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34209,9 +34245,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34243,9 +34279,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34277,9 +34313,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34318,9 +34354,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34352,9 +34388,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34386,9 +34422,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34420,9 +34456,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34454,9 +34490,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34488,9 +34524,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34522,9 +34558,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34556,9 +34592,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34590,9 +34626,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34624,9 +34660,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34658,9 +34694,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34692,9 +34728,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34726,9 +34762,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34760,9 +34796,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34794,9 +34830,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34828,9 +34864,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34862,9 +34898,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34903,9 +34939,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34937,9 +34973,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -34971,9 +35007,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35005,9 +35041,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35039,9 +35075,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35073,9 +35109,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35107,9 +35143,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35141,9 +35177,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35175,9 +35211,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35209,9 +35245,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35243,9 +35279,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35277,9 +35313,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35311,9 +35347,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35345,9 +35381,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35379,9 +35415,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35413,9 +35449,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35447,9 +35483,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35481,9 +35517,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35515,9 +35551,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35549,9 +35585,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35583,9 +35619,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35617,9 +35653,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35651,9 +35687,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35685,9 +35721,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35719,9 +35755,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35753,9 +35789,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35787,9 +35823,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35821,9 +35857,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35855,9 +35891,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35889,9 +35925,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35923,9 +35959,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35957,9 +35993,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -35991,9 +36027,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36025,9 +36061,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36059,9 +36095,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36093,9 +36129,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36127,9 +36163,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36161,9 +36197,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36195,9 +36231,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36229,9 +36265,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36263,9 +36299,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36297,9 +36333,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36331,9 +36367,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36365,9 +36401,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36399,9 +36435,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36433,9 +36469,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36467,9 +36503,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36501,9 +36537,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36535,9 +36571,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36569,9 +36605,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36603,9 +36639,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36637,9 +36673,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36671,9 +36707,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36705,9 +36741,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36739,9 +36775,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36773,9 +36809,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36807,9 +36843,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36841,9 +36877,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36875,9 +36911,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36909,9 +36945,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36943,9 +36979,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -36977,9 +37013,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37011,9 +37047,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37045,9 +37081,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37079,9 +37115,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37113,9 +37149,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37147,9 +37183,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37181,9 +37217,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37215,9 +37251,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37249,9 +37285,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37283,9 +37319,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37317,9 +37353,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37351,9 +37387,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37385,9 +37421,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37419,9 +37455,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37453,9 +37489,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37487,9 +37523,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37521,9 +37557,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37555,9 +37591,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37589,9 +37625,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37623,9 +37659,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37657,9 +37693,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37691,9 +37727,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37725,9 +37761,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37759,9 +37795,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37793,9 +37829,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37827,9 +37863,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37861,9 +37897,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37895,9 +37931,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37929,9 +37965,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37963,9 +37999,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -37997,9 +38033,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38031,9 +38067,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38065,9 +38101,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38099,9 +38135,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38133,9 +38169,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38167,9 +38203,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38201,9 +38237,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38235,9 +38271,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38269,9 +38305,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38303,9 +38339,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38337,9 +38373,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38371,9 +38407,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38405,9 +38441,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38439,9 +38475,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38473,9 +38509,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38507,9 +38543,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38541,9 +38577,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38575,9 +38611,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38609,9 +38645,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38643,9 +38679,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38677,9 +38713,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38711,9 +38747,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38745,9 +38781,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38779,9 +38815,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38813,9 +38849,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38847,9 +38883,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38881,9 +38917,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38915,9 +38951,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38949,9 +38985,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -38983,9 +39019,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39017,9 +39053,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39051,9 +39087,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39085,9 +39121,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39119,9 +39155,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39153,9 +39189,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39187,9 +39223,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39221,9 +39257,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39255,9 +39291,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39289,9 +39325,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39323,9 +39359,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39357,9 +39393,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39391,9 +39427,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39425,9 +39461,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39459,9 +39495,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39493,9 +39529,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39527,9 +39563,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39561,9 +39597,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39595,9 +39631,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39629,9 +39665,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39639,7 +39675,7 @@
 test_xmlunicode(void) {
     int test_ret = 0;
 
-    printf("Testing xmlunicode : 166 of 166 functions ...\n");
+    if (quiet == 0) printf("Testing xmlunicode : 166 of 166 functions ...\n");
     test_ret += test_xmlUCSIsAegeanNumbers();
     test_ret += test_xmlUCSIsAlphabeticPresentationForms();
     test_ret += test_xmlUCSIsArabic();
@@ -39840,9 +39876,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39881,9 +39917,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39922,9 +39958,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -39964,9 +40000,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40012,9 +40048,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40046,9 +40082,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40080,9 +40116,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40114,9 +40150,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40148,9 +40184,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40182,9 +40218,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40216,9 +40252,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40250,9 +40286,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40284,9 +40320,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40318,9 +40354,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40352,9 +40388,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40386,9 +40422,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40420,9 +40456,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40461,9 +40497,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40502,9 +40538,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40543,9 +40579,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40598,9 +40634,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40632,9 +40668,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40666,9 +40702,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40721,9 +40757,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40762,9 +40798,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40803,9 +40839,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40851,9 +40887,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40906,9 +40942,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -40947,9 +40983,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41002,9 +41038,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41043,9 +41079,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41091,9 +41127,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41153,9 +41189,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41208,9 +41244,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41263,9 +41299,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41304,9 +41340,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41345,9 +41381,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41407,9 +41443,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41455,9 +41491,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41503,9 +41539,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41579,9 +41615,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41648,9 +41684,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41703,9 +41739,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41758,9 +41794,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41813,9 +41849,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41861,9 +41897,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -41923,9 +41959,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42101,9 +42137,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42142,9 +42178,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42190,9 +42226,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42231,9 +42267,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42371,7 +42407,7 @@
 test_xmlwriter(void) {
     int test_ret = 0;
 
-    printf("Testing xmlwriter : 51 of 79 functions ...\n");
+    if (quiet == 0) printf("Testing xmlwriter : 51 of 79 functions ...\n");
     test_ret += test_xmlNewTextWriter();
     test_ret += test_xmlNewTextWriterFilename();
     test_ret += test_xmlNewTextWriterMemory();
@@ -42482,9 +42518,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42516,9 +42552,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42550,9 +42586,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42584,9 +42620,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42618,9 +42654,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42652,9 +42688,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42686,9 +42722,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42720,9 +42756,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42754,9 +42790,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42788,9 +42824,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42822,9 +42858,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42856,9 +42892,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42890,9 +42926,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42924,9 +42960,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -42965,9 +43001,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43036,9 +43072,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43071,9 +43107,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43106,9 +43142,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43141,9 +43177,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43192,9 +43228,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43233,9 +43269,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43274,9 +43310,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43299,9 +43335,9 @@
 	    test_ret++;
             printf("\n");
         }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43333,9 +43369,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43367,9 +43403,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43411,9 +43447,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43445,9 +43481,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43479,9 +43515,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43489,7 +43525,7 @@
 test_xpath(void) {
     int test_ret = 0;
 
-    printf("Testing xpath : 28 of 36 functions ...\n");
+    if (quiet == 0) printf("Testing xpath : 28 of 36 functions ...\n");
     test_ret += test_xmlXPathCastBooleanToNumber();
     test_ret += test_xmlXPathCastBooleanToString();
     test_ret += test_xmlXPathCastNodeSetToBoolean();
@@ -43564,9 +43600,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43605,9 +43641,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43637,9 +43673,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43676,9 +43712,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43715,9 +43751,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43763,9 +43799,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43802,9 +43838,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43841,9 +43877,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43880,9 +43916,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43927,10 +43963,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -43975,10 +44011,10 @@
     }
     }
     }
+    function_tests++;
 #endif
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44017,9 +44053,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44051,9 +44087,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44085,9 +44121,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44117,9 +44153,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44151,9 +44187,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44190,9 +44226,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44222,9 +44258,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44263,9 +44299,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44302,9 +44338,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44341,9 +44377,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44402,9 +44438,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44441,9 +44477,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44482,9 +44518,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44516,9 +44552,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44555,9 +44591,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44594,9 +44630,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44635,9 +44671,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44676,9 +44712,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44715,9 +44751,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44747,9 +44783,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44779,9 +44815,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44818,9 +44854,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44852,9 +44888,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44886,9 +44922,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44920,9 +44956,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44954,9 +44990,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -44988,9 +45024,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45032,9 +45068,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45073,9 +45109,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45114,9 +45150,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45155,9 +45191,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45196,9 +45232,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45237,9 +45273,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45278,9 +45314,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45319,9 +45355,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45360,9 +45396,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45401,9 +45437,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45442,9 +45478,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45483,9 +45519,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45524,9 +45560,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45565,9 +45601,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45606,9 +45642,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45647,9 +45683,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45686,9 +45722,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45732,9 +45768,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45771,9 +45807,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45812,9 +45848,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45851,9 +45887,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45892,9 +45928,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45931,9 +45967,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -45963,9 +45999,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46004,9 +46040,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46045,9 +46081,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46084,9 +46120,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46118,9 +46154,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46157,9 +46193,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46198,9 +46234,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46237,9 +46273,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46271,9 +46307,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46305,9 +46341,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46339,9 +46375,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46373,9 +46409,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46407,9 +46443,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46441,9 +46477,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46475,9 +46511,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46514,9 +46550,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46546,9 +46582,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46624,9 +46660,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46672,9 +46708,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46737,9 +46773,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46769,9 +46805,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46801,9 +46837,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46833,9 +46869,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46865,9 +46901,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46904,9 +46940,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46943,9 +46979,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -46977,9 +47013,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47016,9 +47052,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47055,9 +47091,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47087,9 +47123,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47126,9 +47162,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47165,9 +47201,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47204,9 +47240,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47243,9 +47279,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47284,9 +47320,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47325,9 +47361,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47364,9 +47400,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47403,9 +47439,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47435,9 +47471,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47476,9 +47512,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47524,9 +47560,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47558,9 +47594,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47592,9 +47628,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47626,9 +47662,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47679,9 +47715,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47689,7 +47725,7 @@
 test_xpathInternals(void) {
     int test_ret = 0;
 
-    printf("Testing xpathInternals : 106 of 117 functions ...\n");
+    if (quiet == 0) printf("Testing xpathInternals : 106 of 117 functions ...\n");
     test_ret += test_valuePop();
     test_ret += test_valuePush();
     test_ret += test_xmlXPathAddValues();
@@ -47836,9 +47872,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47877,9 +47913,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47909,9 +47945,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -47958,9 +47994,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48007,9 +48043,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48056,9 +48092,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48090,9 +48126,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48134,9 +48170,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48175,9 +48211,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48230,9 +48266,9 @@
     }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48271,9 +48307,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48312,9 +48348,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48353,9 +48389,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48394,9 +48430,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48435,9 +48471,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48474,9 +48510,9 @@
         }
     }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48508,9 +48544,9 @@
             printf("\n");
         }
     }
+    function_tests++;
 #endif
 
-    function_tests++;
     return(test_ret);
 }
 
@@ -48518,7 +48554,7 @@
 test_xpointer(void) {
     int test_ret = 0;
 
-    printf("Testing xpointer : 17 of 21 functions ...\n");
+    if (quiet == 0) printf("Testing xpointer : 17 of 21 functions ...\n");
     test_ret += test_xmlXPtrBuildNodeList();
     test_ret += test_xmlXPtrEval();
     test_ret += test_xmlXPtrEvalRangePredicate();
diff --git a/xmllint.c b/xmllint.c
index 5d720a0..906909f 100644
--- a/xmllint.c
+++ b/xmllint.c
@@ -738,6 +738,7 @@
  * 									*
  ************************************************************************/
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
 /**
  * xmlShellReadline:
  * @prompt:  the prompt value
@@ -778,6 +779,7 @@
     return(ret);
 #endif
 }
+#endif /* LIBXML_XPATH_ENABLED */
 #endif /* LIBXML_DEBUG_ENABLED */
 
 /************************************************************************
@@ -1223,12 +1225,14 @@
 #endif
 
 #ifdef LIBXML_DEBUG_ENABLED
+#ifdef LIBXML_XPATH_ENABLED
     /*
      * shell interaction
      */
     if (shell)  
         xmlShell(doc, filename, xmlShellReadline, stdout);
 #endif
+#endif
 
 #ifdef LIBXML_TREE_ENABLED
     /*
diff --git a/xmlschemastypes.c b/xmlschemastypes.c
index 0a1e5b1..3246362 100644
--- a/xmlschemastypes.c
+++ b/xmlschemastypes.c
@@ -31,6 +31,12 @@
 
 #define DEBUG
 
+#ifndef LIBXML_XPATH_ENABLED
+extern double xmlXPathNAN;
+extern double xmlXPathPINF;
+extern double xmlXPathNINF;
+#endif
+
 #define TODO 								\
     xmlGenericError(xmlGenericErrorContext,				\
 	    "Unimplemented block at %s:%d\n",				\
diff --git a/xmlwriter.c b/xmlwriter.c
index 3255c67..099d3f0 100644
--- a/xmlwriter.c
+++ b/xmlwriter.c
@@ -4405,7 +4405,7 @@
             return;
         }
 #else
-        xmlWriterErrMsg(writer, XML_ERR_INTERNAL_ERROR,
+        xmlWriterErrMsg(NULL, XML_ERR_INTERNAL_ERROR,
                         "libxml2 built without HTML support\n");
         ctxt->errNo = XML_ERR_INTERNAL_ERROR;
         ctxt->instate = XML_PARSER_EOF;