aboutsummaryrefslogtreecommitdiffstats
path: root/entities.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2001-07-04 19:49:14 +0000
committerDaniel Veillard <veillard@src.gnome.org>2001-07-04 19:49:14 +0000
commit62f313ba0cce40d98c42e366a9692f8f11181d7c (patch)
treeaa0c736404bf882b6610d4a7fdacb83be1e10ba5 /entities.c
parentf420ac55f8ddf2137f0b0a99e5639ea0e3a08fe4 (diff)
downloadandroid_external_libxml2-62f313ba0cce40d98c42e366a9692f8f11181d7c.tar.gz
android_external_libxml2-62f313ba0cce40d98c42e366a9692f8f11181d7c.tar.bz2
android_external_libxml2-62f313ba0cce40d98c42e366a9692f8f11181d7c.zip
- SAX.c entities.c parser.c: changed completely the way entities
are handled when running the parser in entity substitution mode. This fixes a bug reported by Stephan Kulow and nearly divides by 3 the amount of memory required by libxslt to load and process DocBook TDG. Daniel
Diffstat (limited to 'entities.c')
-rw-r--r--entities.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/entities.c b/entities.c
index 94f1f6ff..4ecb98c9 100644
--- a/entities.c
+++ b/entities.c
@@ -46,7 +46,7 @@ xmlHashTablePtr xmlPredefinedEntities = NULL;
static void xmlFreeEntity(xmlEntityPtr entity) {
if (entity == NULL) return;
- if (entity->children)
+ if ((entity->children) && (entity->children->parent == entity))
xmlFreeNodeList(entity->children);
if (entity->name != NULL)
xmlFree((char *) entity->name);