Re: svn commit: r1683895 - /subversion/trunk/subversion/libsvn_delta/svndiff.c
On 06.06.2015 13:42, ivan_at_apache.org wrote:
> Author: ivan
> Date: Sat Jun 6 11:42:31 2015
> New Revision: 1683895
> URL: http://svn.apache.org/r1683895
> Simplify code and avoid multiple buffer reallocation for every delta
> window in SVNDIFF stream processing.
> * subversion/libsvn_delta/svndiff.c
> (write_handler): Use svn_stringbuf_remove() to remove processed
> window data from buffer. Clear subpool on every window procesing
> instead of creating new subpool and destroy old one.
> (svn_txdelta_parse_svndiff): Allocate DB->BUFFER in DB->POOL instead of
If you're optimizing that code, you could consider dropping
svn_stringbuf_t entirely and switching to (private) svn_membuf_t. The
advantage of that is that stringbuf always keeps a NUL terminator at the
end of the data, whereas membuf does not.
Received on 2015-06-06 15:48:28 CEST
This is an archived mail posted to the Subversion Dev