Harden XmlReader
Build / AerScript (push) Successful in 14s

This commit is contained in:
2026-11-22 16:25:36 +01:00
parent 4d47dac2b1
commit e99462aea1
4 changed files with 408 additions and 260 deletions
+10 -1
View File
@@ -63,9 +63,18 @@ enum xml_err_code {
SXML_ERROR_UNKNOWN_ENCODING,
SXML_ERROR_INCORRECT_ENCODING,
SXML_ERROR_UNCLOSED_CDATA_SECTION,
SXML_ERROR_EXTERNAL_ENTITY_HANDLING
SXML_ERROR_EXTERNAL_ENTITY_HANDLING,
/* Module-level conditions (not produced by the SAX tokenizer). */
SXML_ERROR_INVALID_OPERATION,
SXML_ERROR_TYPE_MISMATCH
};
/* SyHashGet() ignores zero-length keys, so the default namespace cannot be
* stored under "". Use a non-printable one-byte sentinel instead. */
#define SXML_DEFAULT_NS_KEY '\x01'
#define SXML_DEFAULT_NS_KEY_STR "\x01"
#define SXML_DEFAULT_NS_KEY_LEN 1
/*
* An XML raw text,CDATA,tag name and son is parsed out and stored
* in an instance of the following structure.