Implement our own output buffering inside saxdb.
src/saxdb.c (SAXDB_BUFFER_SIZE): Default to 32 KB if not already defined.
(struct saxdb_context): Add "obuf" member.
(saxdb_flush): Define new helper function.
(saxdb_put_char): Convert to function.
(saxdb_put_nchars): Update to use "obuf" and saxdb_flush().
(saxdb_put_string): Update to use saxdb_put_nchars().
(saxdb_put_qstring): Likewise.
(saxdb_open_context): Allocate space for ctx->obuf.
(saxdb_close_context): Flush the buffer and free ctx->obuf.