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

Function xmlTextWriterWriteVFormatComment

ThirdParty/libxml2/vtklibxml2/xmlwriter.c:884–905  ·  view source on GitHub ↗

* xmlTextWriterWriteVFormatComment: * @writer: the xmlTextWriterPtr * @format: format string (see printf) * @argptr: pointer to the first member of the variable argument list. * * Write an xml comment. * * Returns the bytes written (may be 0 because of buffering) or -1 in case of error */

Source from the content-addressed store, hash-verified

882 * Returns the bytes written (may be 0 because of buffering) or -1 in case of error
883 */
884int
885xmlTextWriterWriteVFormatComment(xmlTextWriterPtr writer,
886 const char *format, va_list argptr)
887{
888 int rc;
889 xmlChar *buf;
890
891 if (writer == NULL) {
892 xmlWriterErrMsg(writer, XML_ERR_INTERNAL_ERROR,
893 "xmlTextWriterWriteVFormatComment : invalid writer!\n");
894 return -1;
895 }
896
897 buf = xmlTextWriterVSprintf(format, argptr);
898 if (buf == NULL)
899 return -1;
900
901 rc = xmlTextWriterWriteComment(writer, buf);
902
903 xmlFree(buf);
904 return rc;
905}
906
907/**
908 * xmlTextWriterWriteComment:

Callers 1

Calls 3

xmlWriterErrMsgFunction · 0.85
xmlTextWriterVSprintfFunction · 0.85

Tested by

no test coverage detected