mirror of
https://github.com/darlinghq/darling-libxml2.git
synced 2024-12-03 09:50:51 +00:00
two small improvements Daniel
* dict.c xmlreader.c: two small improvements Daniel
This commit is contained in:
parent
a66b1d1a7d
commit
ccc4d2b62e
@ -1,3 +1,7 @@
|
||||
Wed Sep 17 23:25:47 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* dict.c xmlreader.c: two small improvements
|
||||
|
||||
Wed Sep 17 22:53:32 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* parserInternals.c: avoid a leak with previous patch
|
||||
|
3
dict.c
3
dict.c
@ -338,6 +338,9 @@ xmlDictLookup(xmlDictPtr dict, const xmlChar *name, int len) {
|
||||
if ((dict == NULL) || (name == NULL))
|
||||
return(NULL);
|
||||
|
||||
if ((name[len] == 0) && (xmlDictOwns(dict, name) == 1))
|
||||
return(name);
|
||||
|
||||
if (len < 0)
|
||||
len = xmlStrlen(name);
|
||||
|
||||
|
@ -1272,6 +1272,7 @@ node_found:
|
||||
* If we are in the middle of a piece of CDATA make sure it's finished
|
||||
*/
|
||||
if ((reader->node != NULL) &&
|
||||
(reader->node->next == NULL) &&
|
||||
((reader->node->type == XML_TEXT_NODE) ||
|
||||
(reader->node->type == XML_CDATA_SECTION_NODE))) {
|
||||
xmlTextReaderExpand(reader);
|
||||
|
Loading…
Reference in New Issue
Block a user