diff options
author | Daniel Veillard <veillard@src.gnome.org> | 1999-12-28 16:35:14 +0000 |
---|---|---|
committer | Daniel Veillard <veillard@src.gnome.org> | 1999-12-28 16:35:14 +0000 |
commit | dbfd641b78b5a98e790459e13d126e2784a7adeb (patch) | |
tree | 9f7fce862646ec3feaad8e8ba23bbec56187d8aa /entities.c | |
parent | fef854d2347ea4a6bab052b93d0e591317d2a94a (diff) | |
download | libxml2-dbfd641b78b5a98e790459e13d126e2784a7adeb.tar.gz |
- Lots of improvements, too long to list here
- Push mode for the XML parser (HTML to come)
- XML shell like interface for debug
- improvements on XPath and validation
Daniel
Diffstat (limited to 'entities.c')
-rw-r--r-- | entities.c | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -114,10 +114,13 @@ xmlAddEntity(xmlEntitiesTablePtr table, const xmlChar *name, int type, cur->SystemID = xmlStrdup(SystemID); else cur->SystemID = NULL; - if (content != NULL) - cur->content = xmlStrdup(content); - else + if (content != NULL) { + cur->length = xmlStrlen(content); + cur->content = xmlStrndup(content, cur->length); + } else { + cur->length = 0; cur->content = NULL; + } cur->orig = NULL; table->nb_entities++; } |