MCPcopy Create free account
hub / github.com/Kitware/VTK / xmlTextWriterWriteDocCallback

Function xmlTextWriterWriteDocCallback

ThirdParty/libxml2/vtklibxml2/xmlwriter.c:4440–4454  ·  view source on GitHub ↗

* xmlTextWriterWriteDocCallback: * @context: the xmlBufferPtr * @str: the data to write * @len: the length of the data * * Write callback for the xmlOutputBuffer with target xmlBuffer * * Returns -1, 0, 1 */

Source from the content-addressed store, hash-verified

4438 * Returns -1, 0, 1
4439 */
4440static int
4441xmlTextWriterWriteDocCallback(void *context, const char *str, int len)
4442{
4443 xmlParserCtxtPtr ctxt = (xmlParserCtxtPtr) context;
4444 int rc;
4445
4446 if ((rc = xmlParseChunk(ctxt, str, len, 0)) != 0) {
4447 xmlWriterErrMsgInt(NULL, XML_ERR_INTERNAL_ERROR,
4448 "xmlTextWriterWriteDocCallback : XML error %d !\n",
4449 rc);
4450 return -1;
4451 }
4452
4453 return len;
4454}
4455
4456/**
4457 * xmlTextWriterCloseDocCallback:

Callers

nothing calls this directly

Calls 1

xmlParseChunkFunction · 0.85

Tested by

no test coverage detected