Add svn_rangelist_merge2() which modifies the rangelist in-place to produce its result, instead of allocating a new rangelist, and also uses the dual-pool paradigm. The previous svn_rangelist_merge() implementation was awkward to call from within a loop without potentially using a lot of memory (see r1148566 for an example).
* subversion/libsvn_subr/deprecated.c (svn_rangelist_merge): Implement as a wrapper around svn_rangelist_merge2().
* subversion/libsvn_subr/mergeinfo.c (svn_rangelist_merge): Rename to ... (svn_rangelist_merge2): ... this. Change the RANGELIST parameter to an apr_array_header_t* (rather than apr_array_header_t**). Replace the POOL parameter with RESULT_POOL and SCRATCH_POOL parameters. Produce the merged rangelist in place, allocating any elements newly added to the array in RESULT_POOL.