diff options
author | Daniel Veillard <veillard@src.gnome.org> | 2001-03-27 12:47:33 +0000 |
---|---|---|
committer | Daniel Veillard <veillard@src.gnome.org> | 2001-03-27 12:47:33 +0000 |
commit | 92ad210417f318c8f0142fd0aee8d2893d83b8e8 (patch) | |
tree | 03308d8014ae764458f3cd79ebfc26211bde14ce /entities.c | |
parent | 2be30641d1bc09321889b415cd0f5a2e24c1efb8 (diff) | |
download | android_external_libxml2-92ad210417f318c8f0142fd0aee8d2893d83b8e8.tar.gz android_external_libxml2-92ad210417f318c8f0142fd0aee8d2893d83b8e8.tar.bz2 android_external_libxml2-92ad210417f318c8f0142fd0aee8d2893d83b8e8.zip |
Spring cleanup ...: - configure.in Makefile.am config.h.in
Spring cleanup ...:
- configure.in Makefile.am config.h.in xmlversion.h.in: detect if
we need string functions
- trio.[ch] strio.[ch]: embedded the Trio-0.23 string functions
to be able to use them where needed. Applied some changes
to reduce name linking pollution and compile in only what's
needed.
- HTMLtree.c debugXML.c entities.c error.c nanoftp.c valid.c
xlink.c xmlversion.h.in xpath.c: got rid of the #ifdef
for the string manipulation functions
- xmlmemory.[ch]: removed DEBUG_MEMORY_FREED and added it automatically
to the free() function of xmlmemory.c
- entities.c HTMLtree.c parserInternals.c tree.c uri.c valid.c
xinclude.c xmlIO.c xpath.c xpointer.c: removed the MEM_CLEANUP
usage.
Daniel
Diffstat (limited to 'entities.c')
-rw-r--r-- | entities.c | 25 |
1 files changed, 0 insertions, 25 deletions
@@ -67,7 +67,6 @@ static void xmlFreeEntity(xmlEntityPtr entity) { xmlFree((char *) entity->content); if (entity->orig != NULL) xmlFree((char *) entity->orig); - MEM_CLEANUP(entity, sizeof(xmlEntity)); xmlFree(entity); } @@ -521,11 +520,7 @@ xmlEncodeEntities(xmlDocPtr doc, const xmlChar *input) { } else if ((sizeof(xmlChar) == 1) && (*cur >= 0x80)) { char buf[10], *ptr; -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#%d;", *cur); -#else - sprintf(buf, "&#%d;", *cur); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; @@ -533,11 +528,7 @@ xmlEncodeEntities(xmlDocPtr doc, const xmlChar *input) { } else if (IS_CHAR(*cur)) { char buf[10], *ptr; -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#%d;", *cur); -#else - sprintf(buf, "&#%d;", *cur); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; @@ -679,11 +670,7 @@ xmlEncodeEntitiesReentrant(xmlDocPtr doc, const xmlChar *input) { xmlGenericError(xmlGenericErrorContext, "xmlEncodeEntitiesReentrant : input not UTF-8\n"); doc->encoding = xmlStrdup(BAD_CAST "ISO-8859-1"); -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#%d;", *cur); -#else - sprintf(buf, "&#%d;", *cur); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; @@ -714,11 +701,7 @@ xmlEncodeEntitiesReentrant(xmlDocPtr doc, const xmlChar *input) { xmlGenericError(xmlGenericErrorContext, "xmlEncodeEntitiesReentrant : char out of range\n"); doc->encoding = xmlStrdup(BAD_CAST "ISO-8859-1"); -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#%d;", *cur); -#else - sprintf(buf, "&#%d;", *cur); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; @@ -728,11 +711,7 @@ xmlEncodeEntitiesReentrant(xmlDocPtr doc, const xmlChar *input) { /* * We could do multiple things here. Just save as a char ref */ -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#x%X;", val); -#else - sprintf(buf, "&#x%X;", val); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; @@ -742,11 +721,7 @@ xmlEncodeEntitiesReentrant(xmlDocPtr doc, const xmlChar *input) { } else if (IS_CHAR(*cur)) { char buf[10], *ptr; -#ifdef HAVE_SNPRINTF snprintf(buf, sizeof(buf), "&#%d;", *cur); -#else - sprintf(buf, "&#%d;", *cur); -#endif buf[sizeof(buf) - 1] = 0; ptr = buf; while (*ptr != 0) *out++ = *ptr++; |