Remove inadequate check for duplicate "xml" PI.
authorTom Lane <[email protected]>
Sat, 23 Mar 2019 21:40:19 +0000 (17:40 -0400)
committerTom Lane <[email protected]>
Sat, 23 Mar 2019 21:40:19 +0000 (17:40 -0400)
I failed to think about PIs starting with "xml".  We don't really
need this check at all, so just take it out.  Oversight in
commit 8d1dadb25 et al.

src/backend/utils/adt/xml.c

index 931f4c3e8fd6b893a76811c597f9a35ed37d48be..c215be348ad8e464bbf636e6f1e87d2164d73a02 100644 (file)
@@ -1400,10 +1400,6 @@ xml_doctype_in_content(const xmlChar *str)
        if (!e)
            return false;
 
-       /* we don't check PIs carefully, but do reject "xml" target */
-       if (e - p >= 3 && xmlStrncasecmp(p, (xmlChar *) "xml", 3) == 0)
-           return false;
-
        /* advance over PI, keep scanning */
        p = e + 2;
    }