Index: subversion/include/svn_repos.h =================================================================== --- subversion/include/svn_repos.h (revision 4517) +++ subversion/include/svn_repos.h (working copy) @@ -220,7 +220,8 @@ */ svn_error_t *svn_repos_set_path (void *report_baton, const char *path, - svn_revnum_t revision); + svn_revnum_t revision, + apr_pool_t *pool); /** Given a @a report_baton constructed by @c svn_repos_begin_report(), Index: subversion/include/svn_ra.h =================================================================== --- subversion/include/svn_ra.h (revision 4517) +++ subversion/include/svn_ra.h (working copy) @@ -132,7 +132,8 @@ */ svn_error_t *(*set_path) (void *report_baton, const char *path, - svn_revnum_t revision); + svn_revnum_t revision, + apr_pool_t *pool); /** Describing a working copy @a path as missing. */ svn_error_t *(*delete_path) (void *report_baton, Index: subversion/libsvn_wc/adm_crawler.c =================================================================== --- subversion/libsvn_wc/adm_crawler.c (revision 4517) +++ subversion/libsvn_wc/adm_crawler.c (working copy) @@ -131,7 +131,7 @@ { apr_hash_t *entries, *dirents; apr_hash_index_t *hi; - apr_pool_t *subpool = svn_pool_create (pool); + apr_pool_t *subpool = svn_pool_create (pool), *child_subpool; const svn_wc_entry_t *dot_entry; const char *this_url, *this_path, *this_full_path; svn_wc_adm_access_t *dir_access; @@ -180,6 +180,8 @@ } /* Looping over current directory's SVN entries: */ + child_subpool = svn_pool_create(subpool); + for (hi = apr_hash_first (subpool, entries); hi; hi = apr_hash_next (hi)) { const void *key; @@ -204,14 +206,18 @@ It needs a more thorough rewrite, but for now we paper it over with a terrifyingly ugly kluge. */ - svn_stringbuf_t *this_path_s = svn_stringbuf_create (this_path, pool); - svn_stringbuf_t *dir_path_s = svn_stringbuf_create (dir_path, pool); - svn_stringbuf_t *full_path_s = svn_stringbuf_create (full_path, pool); + svn_stringbuf_t *this_path_s = svn_stringbuf_create (this_path, + child_subpool); + svn_stringbuf_t *dir_path_s = svn_stringbuf_create (dir_path, + child_subpool); + svn_stringbuf_t *full_path_s = svn_stringbuf_create (full_path, + child_subpool); svn_stringbuf_t *this_full_path_s - = svn_stringbuf_create (this_full_path, pool); - svn_stringbuf_t *this_url_s = svn_stringbuf_create (this_url, pool); + = svn_stringbuf_create (this_full_path, child_subpool); + svn_stringbuf_t *this_url_s = svn_stringbuf_create (this_url, + child_subpool); svn_stringbuf_t *dot_entry_url_s - = svn_stringbuf_create (dot_entry-url, pool); + = svn_stringbuf_create (dot_entry-url, child_subpool); if (this_path_s-len dir_path_s-len) svn_stringbuf_chop (this_path_s, this_path_s-len - dir_path_s-len); @@ -224,7 +230,7 @@ svn_path_add_component (this_path_s, key); svn_path_add_component (this_full_path_s, key); svn_path_add_component (this_url_s, - svn_path_uri_encode (key, pool)); + svn_path_uri_encode (key, child_subpool)); this_path = this_path_s-data; this_full_path = this_full_path_s-data; @@ -267,7 +273,8 @@ (current_entry-schedule != svn_wc_schedule_replace)) { /* Recreate file from text-base. */ - SVN_ERR (restore_file (this_full_path, dir_access, pool)); + SVN_ERR (restore_file (this_full_path, dir_access, + child_subpool)); /* Report the restoration to the caller. */ if (notify_func != NULL) @@ -294,7 +301,8 @@ else if (current_entry-revision != dir_rev) SVN_ERR (reporter-set_path (report_baton, this_path, - current_entry-revision)); + current_entry-revision, + child_subpool)); } else if (current_entry-kind == svn_node_dir recurse) @@ -325,9 +333,9 @@ /* We need to read the full entry of the directory from its own this dir, if available. */ SVN_ERR (svn_wc_adm_retrieve (subdir_access, adm_access, - this_full_path, subpool)); + this_full_path, child_subpool)); SVN_ERR (svn_wc_entry (subdir_entry, this_full_path, subdir_access, - TRUE, subpool)); + TRUE, child_subpool)); /* Possibly report a disjoint URL... */ if (strcmp (subdir_entry-url, this_url) != 0) @@ -339,7 +347,8 @@ else if (subdir_entry-revision != dir_rev) SVN_ERR (reporter-set_path (report_baton, this_path, - subdir_entry-revision)); + subdir_entry-revision, + child_subpool)); /* Recurse. */ SVN_ERR (report_revisions (adm_access, this_path, @@ -348,9 +357,10 @@ notify_func, notify_baton, restore_files, recurse, traversal_info, - subpool)); + child_subpool)); } /* end directory case */ + svn_pool_clear (child_subpool); } /* end main entries loop */ /* We're done examining this dir's entries, so free everything. */ @@ -401,7 +411,7 @@ /* The first call to the reporter merely informs it that the top-level directory being updated is at BASE_REV. Its PATH argument is ignored. */ - SVN_ERR (reporter-set_path (report_baton, , base_rev)); + SVN_ERR (reporter-set_path (report_baton, , base_rev, pool)); if (entry-schedule != svn_wc_schedule_delete) { @@ -492,7 +502,7 @@ of the report (not some file in a subdirectory of a target directory), and that target is a file, we need to pass an empty string to set_path. */ - err = reporter-set_path (report_baton, , base_rev); + err = reporter-set_path (report_baton, , base_rev, pool); if (err) goto abort_report; } Index: subversion/libsvn_ra_local/ra_plugin.c =================================================================== --- subversion/libsvn_ra_local/ra_plugin.c (revision 4517) +++ subversion/libsvn_ra_local/ra_plugin.c (working copy) @@ -120,10 +120,11 @@ static svn_error_t * reporter_set_path (void *reporter_baton, const char *path, - svn_revnum_t revision) + svn_revnum_t revision, + apr_pool_t *pool) { reporter_baton_t *rbaton = reporter_baton; - return svn_repos_set_path (rbaton-report_baton, path, revision); + return svn_repos_set_path (rbaton-report_baton, path, revision, pool); } Index: subversion/libsvn_client/diff.c =================================================================== --- subversion/libsvn_client/diff.c (revision 4517) +++ subversion/libsvn_client/diff.c (working copy) @@ -821,7 +821,7 @@ URL2, diff_editor, diff_edit_baton)); - SVN_ERR (reporter-set_path (report_baton, , start_revnum)); + SVN_ERR (reporter-set_path (report_baton, , start_revnum, pool)); SVN_ERR (reporter-finish_report (report_baton)); @@ -1273,7 +1273,7 @@ URL2, diff_editor, diff_edit_baton)); - SVN_ERR (reporter-set_path (report_baton, , start_revnum)); + SVN_ERR (reporter-set_path (report_baton, , start_revnum, pool)); SVN_ERR (reporter-finish_report (report_baton)); SVN_ERR (ra_lib-close (session2)); Index: subversion/mod_dav_svn/update.c =================================================================== --- subversion/mod_dav_svn/update.c (revision 4517) +++ subversion/mod_dav_svn/update.c (working copy) @@ -830,7 +830,7 @@ path = dav_xml_get_cdata(child, resource-pool, 1); if (! linkpath) - serr = svn_repos_set_path(rbaton, path, rev); + serr = svn_repos_set_path(rbaton, path, rev, resource-pool); else serr = svn_repos_link_path(rbaton, path, linkpath, rev); if (serr != NULL) Index: subversion/libsvn_repos/reporter.c =================================================================== --- subversion/libsvn_repos/reporter.c (revision 4517) +++ subversion/libsvn_repos/reporter.c (working copy) @@ -146,16 +146,17 @@ svn_error_t * svn_repos_set_path (void *report_baton, const char *path, - svn_revnum_t revision) + svn_revnum_t revision, + apr_pool_t *pool) { svn_repos_report_baton_t *rbaton = report_baton; - svn_revnum_t *rev_ptr = apr_palloc (rbaton-pool, sizeof (*rev_ptr)); + svn_revnum_t *rev_ptr = apr_palloc (pool, sizeof (*rev_ptr)); /* If this is the very first call, no txn exists yet. */ if (! rbaton-txn) { /* ### need to change svn_path_is_empty() */ - svn_stringbuf_t *pathbuf = svn_stringbuf_create (path, rbaton-pool); + svn_stringbuf_t *pathbuf = svn_stringbuf_create (path, pool); /* Sanity check: make that we didn't call this with real data before simply informing the reporter of our base revision. */ @@ -186,7 +187,7 @@ reported) + path (stuff relative to the target...this is the empty string in the file case since the target is the file itself, not a directory containing the file). */ - from_path = svn_path_join_many (rbaton-pool, + from_path = svn_path_join_many (pool, rbaton-base_path, rbaton-target ? rbaton-target : path, rbaton-target ? path : NULL, @@ -196,19 +197,19 @@ which case we'll be linking from somewhere entirely different. */ link_path = get_from_path_map (rbaton-linked_paths, from_path, - rbaton-pool); + pool); /* Create the from root. */ SVN_ERR (svn_fs_revision_root (from_root, rbaton-repos-fs, - revision, rbaton-pool)); + revision, pool)); /* Copy into our txn (use svn_fs_revision_link if we can). */ if (strcmp (link_path, from_path)) SVN_ERR (svn_fs_copy (from_root, link_path, - rbaton-txn_root, from_path, rbaton-pool)); + rbaton-txn_root, from_path, pool)); else SVN_ERR (svn_fs_revision_link (from_root, rbaton-txn_root, - from_path, rbaton-pool)); + from_path, pool)); } return SVN_NO_ERROR; Index: subversion/libsvn_ra_svn/client.c =================================================================== --- subversion/libsvn_ra_svn/client.c (revision 4517) +++ subversion/libsvn_ra_svn/client.c (working copy) @@ -159,10 +159,9 @@ /* --- REPORTER IMPLEMENTATION --- */ static svn_error_t *ra_svn_set_path(void *baton, const char *path, - svn_revnum_t rev) + svn_revnum_t rev, apr_pool_t *pool) { ra_svn_reporter_baton_t *b = baton; - apr_pool_t *pool = b-pool; SVN_ERR(svn_ra_svn_write_cmd(b-conn, pool, set-path, cr, path, rev)); SVN_ERR(svn_ra_svn_read_cmd_response(b-conn, pool, )); Index: subversion/libsvn_ra_dav/fetch.c =================================================================== --- subversion/libsvn_ra_dav/fetch.c (revision 4517) +++ subversion/libsvn_ra_dav/fetch.c (working copy) @@ -2223,15 +2223,16 @@ static svn_error_t * reporter_set_path(void *report_baton, const char *path, - svn_revnum_t revision) + svn_revnum_t revision, + apr_pool_t *pool) { report_baton_t *rb = report_baton; apr_status_t status; const char *entry; svn_stringbuf_t *qpath = NULL; - svn_xml_escape_cstring (qpath, path, rb-ras-pool); - entry = apr_psprintf(rb-ras-pool, + svn_xml_escape_cstring (qpath, path, pool); + entry = apr_psprintf(pool, S:entry rev=\% SVN_REVNUM_T_FMT \%s/S:entry DEBUG_CR, Index: subversion/svnserve/serve.c =================================================================== --- subversion/svnserve/serve.c (revision 4517) +++ subversion/svnserve/serve.c (working copy) @@ -75,7 +75,7 @@ svn_revnum_t rev; SVN_ERR(svn_ra_svn_parse_tuple(params, pool, cr, path, rev)); - SVN_CMD_ERR(svn_repos_set_path(b-report_baton, path, rev)); + SVN_CMD_ERR(svn_repos_set_path(b-report_baton, path, rev, pool)); SVN_ERR(svn_ra_svn_write_cmd_response(conn, pool, )); return SVN_NO_ERROR; }