[libxml2/2.9] Fix --without-valid build




commit 646fe48d1c8a74310c409ddf81fe7df6700052af
Author: Nick Wellnhofer <wellnhofer aevum de>
Date:   Tue Feb 22 11:51:08 2022 +0100

    Fix --without-valid build
    
    Regressed in commit 652dd12a.

 valid.c | 58 +++++++++++++++++++++++++++++-----------------------------
 1 file changed, 29 insertions(+), 29 deletions(-)
---
diff --git a/valid.c b/valid.c
index 8e596f1d..9684683a 100644
--- a/valid.c
+++ b/valid.c
@@ -479,35 +479,6 @@ nodeVPop(xmlValidCtxtPtr ctxt)
     return (ret);
 }
 
-/**
- * xmlValidNormalizeString:
- * @str: a string
- *
- * Normalize a string in-place.
- */
-static void
-xmlValidNormalizeString(xmlChar *str) {
-    xmlChar *dst;
-    const xmlChar *src;
-
-    if (str == NULL)
-        return;
-    src = str;
-    dst = str;
-
-    while (*src == 0x20) src++;
-    while (*src != 0) {
-       if (*src == 0x20) {
-           while (*src == 0x20) src++;
-           if (*src != 0)
-               *dst++ = 0x20;
-       } else {
-           *dst++ = *src++;
-       }
-    }
-    *dst = 0;
-}
-
 #ifdef DEBUG_VALID_ALGO
 static void
 xmlValidPrintNode(xmlNodePtr cur) {
@@ -2636,6 +2607,35 @@ xmlDumpNotationTable(xmlBufferPtr buf, xmlNotationTablePtr table) {
            (xmlDictOwns(dict, (const xmlChar *)(str)) == 0)))  \
            xmlFree((char *)(str));
 
+/**
+ * xmlValidNormalizeString:
+ * @str: a string
+ *
+ * Normalize a string in-place.
+ */
+static void
+xmlValidNormalizeString(xmlChar *str) {
+    xmlChar *dst;
+    const xmlChar *src;
+
+    if (str == NULL)
+        return;
+    src = str;
+    dst = str;
+
+    while (*src == 0x20) src++;
+    while (*src != 0) {
+       if (*src == 0x20) {
+           while (*src == 0x20) src++;
+           if (*src != 0)
+               *dst++ = 0x20;
+       } else {
+           *dst++ = *src++;
+       }
+    }
+    *dst = 0;
+}
+
 static int
 xmlIsStreaming(xmlValidCtxtPtr ctxt) {
     xmlParserCtxtPtr pctxt;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]