Be more lenient with errors in xml file. If there are errors, try to keep loading it anyways.
Dana Jansens danakj@orodu.net
1 files changed,
2 insertions(+),
1 deletions(-)
jump to
M
parser/parse.c
→
parser/parse.c
@@ -152,7 +152,8 @@ return FALSE;
/* XML_PARSE_BLANKS is needed apparently. When it loads a theme file, without this option, the tree is weird and has extra nodes in it. */ - if ((*doc = xmlReadFile(path, NULL, XML_PARSE_NOBLANKS))) { + if ((*doc = xmlReadFile(path, NULL, + XML_PARSE_NOBLANKS | XML_PARSE_RECOVER))) { *root = xmlDocGetRootElement(*doc); if (!*root) { xmlFreeDoc(*doc);