1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-08-01 10:06:59 +03:00

get rid of all the perror() calls made in the library execution paths.

* DOCBparser.c HTMLparser.c c14n.c entities.c list.c
  parser.c parserInternals.c xmlIO.c: get rid of all the
  perror() calls made in the library execution paths. This
  should fix both #92059 and #92385
Daniel
This commit is contained in:
Daniel Veillard
2002-09-05 11:33:25 +00:00
parent 19aa70245a
commit 3487c8d9bb
9 changed files with 65 additions and 118 deletions

View File

@ -2351,7 +2351,7 @@ xmlNewParserCtxt()
if (ctxt == NULL) {
xmlGenericError(xmlGenericErrorContext,
"xmlNewParserCtxt : cannot allocate context\n");
perror("malloc");
xmlGenericError(xmlGenericErrorContext, "malloc failed");
return(NULL);
}
memset(ctxt, 0, sizeof(xmlParserCtxt));
@ -2767,7 +2767,8 @@ xmlDecodeEntities(xmlParserCtxtPtr ctxt ATTRIBUTE_UNUSED, int len ATTRIBUTE_UNUS
buffer_size = XML_PARSER_BIG_BUFFER_SIZE;
buffer = (xmlChar *) xmlMalloc(buffer_size * sizeof(xmlChar));
if (buffer == NULL) {
perror("xmlDecodeEntities: malloc failed");
xmlGenericError(xmlGenericErrorContext,
"xmlDecodeEntities: malloc failed");
return(NULL);
}