Hi Daniel,
I don't really know SGML, so such patches are welcome. I just have one problem with the code, it calls GROW only when the end of the buffer is detected with a NUL, I would rather have it called more preemtively to in the loop to avoid a potential weakness in the case of multibyte chars.
I have changed the patch to call GROW in the loop each time before moving on to the next character. (I don't know whether I should be calling SHRINK as well, though?)
Note also that I prefer patches than cut an paste of full routines, it gives me the context of what was changed.
Here is a unified diff, is that the right format? Best regards, Michael -- Print XML with Prince! http://www.princexml.com
Attachment:
patch
Description: Text document