Merge the r1481800 group from trunk:

 * r1481800, r1481813
   Use result_pool for items copied to output array.
   Justification:
     Allocate output in correct pool to avoid possible memory use after clear.
   Votes:
     +1: philip, brane, stsp
     +1: rhuijben (r1481800 only)



git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.8.x@1482135 13f79535-47bb-0310-9956-ffa450edef68