I'm trying to use an unbuffered FormatterToXML object and I'm
encountering an assertion in flushChars because m_charBuf.size() == 0.
I think that this can easily be fixed by changing
FormatterToXML.flushFunction to NULL if the output is not buffered and
changing FormatterToXML::endDocument() as follows:
void
FormatterToXML::endDocument()
{
- assert(m_flushFunction != 0);
if(m_doIndent == true && m_isprevtext == false)
{
outputLineSep();
}
+ if (m_flushFunction != 0)
- (this->*m_flushFunction)()
(this->*m_flushFunction)();
flushWriter();
}
Let me know if this is a known problem and if my fix is reasonable.
Right now, I guess that it is not possible to do unbuffered XML
output.
Cheers,
Brian