mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-28 00:21:53 +03:00
when creating a DOCTYPE use "html" lowercase by default instead of "HTML"
* HTMLparser.c: when creating a DOCTYPE use "html" lowercase by default instead of "HTML" * parser.c xmlreader.c: optimization, gain a few % parsing speed by avoiding calls to "areBlanks" when not needed. * include/libxml/parser.h include/libxml/tree.h: some structure extensions for future work on using per-document dictionaries. Daniel
This commit is contained in:
18
parser.c
18
parser.c
@ -2799,18 +2799,18 @@ get_more:
|
||||
}
|
||||
nbchar = in - ctxt->input->cur;
|
||||
if (nbchar > 0) {
|
||||
if (IS_BLANK(*ctxt->input->cur)) {
|
||||
if ((ctxt->sax->ignorableWhitespace !=
|
||||
ctxt->sax->characters) &&
|
||||
(IS_BLANK(*ctxt->input->cur))) {
|
||||
const xmlChar *tmp = ctxt->input->cur;
|
||||
ctxt->input->cur = in;
|
||||
|
||||
if (areBlanks(ctxt, tmp, nbchar)) {
|
||||
if (ctxt->sax->ignorableWhitespace != NULL)
|
||||
ctxt->sax->ignorableWhitespace(ctxt->userData,
|
||||
tmp, nbchar);
|
||||
} else {
|
||||
if (ctxt->sax->characters != NULL)
|
||||
ctxt->sax->characters(ctxt->userData,
|
||||
tmp, nbchar);
|
||||
}
|
||||
ctxt->sax->ignorableWhitespace(ctxt->userData,
|
||||
tmp, nbchar);
|
||||
} else if (ctxt->sax->characters != NULL)
|
||||
ctxt->sax->characters(ctxt->userData,
|
||||
tmp, nbchar);
|
||||
line = ctxt->input->line;
|
||||
col = ctxt->input->col;
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user