summaryrefslogtreecommitdiff
path: root/subversion/libsvn_repos/load-fs-vtable.c
diff options
context:
space:
mode:
Diffstat (limited to 'subversion/libsvn_repos/load-fs-vtable.c')
-rw-r--r--subversion/libsvn_repos/load-fs-vtable.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/subversion/libsvn_repos/load-fs-vtable.c b/subversion/libsvn_repos/load-fs-vtable.c
index f6c6bf6..6746065 100644
--- a/subversion/libsvn_repos/load-fs-vtable.c
+++ b/subversion/libsvn_repos/load-fs-vtable.c
@@ -75,7 +75,7 @@ struct parse_baton
(svn_revnum_t *) in the dump stream to their corresponding revisions
(svn_revnum_t *) in the loaded repository. The hash and its
contents are allocated in POOL. */
- /* ### See http://subversion.tigris.org/issues/show_bug.cgi?id=3903
+ /* ### See https://issues.apache.org/jira/browse/SVN-3903
### for discussion about improving the memory costs of this mapping. */
apr_hash_t *rev_map;
@@ -213,9 +213,11 @@ prefix_mergeinfo_paths(svn_string_t **mergeinfo_val,
{
const char *merge_source = apr_hash_this_key(hi);
svn_rangelist_t *rangelist = apr_hash_this_val(hi);
- const char *path;
+ const char *path, *canonicalized_path;
- merge_source = svn_relpath_canonicalize(merge_source, pool);
+ SVN_ERR(svn_relpath_canonicalize_safe(&canonicalized_path, NULL,
+ merge_source, pool, pool));
+ merge_source = canonicalized_path;
/* The svn:mergeinfo property syntax demands a repos abspath */
path = svn_fspath__canonicalize(svn_relpath_join(parent_dir,
@@ -253,7 +255,7 @@ renumber_mergeinfo_revs(svn_string_t **final_val,
SVN_ERR(svn_mergeinfo_parse(&mergeinfo, initial_val->data, subpool));
/* Issue #3020
- http://subversion.tigris.org/issues/show_bug.cgi?id=3020#desc16
+ https://issues.apache.org/jira/browse/SVN-3020#desc16
Remove mergeinfo older than the oldest revision in the dump stream
and adjust its revisions by the difference between the head rev of
the target repository and the current dump stream rev. */
@@ -323,7 +325,7 @@ renumber_mergeinfo_revs(svn_string_t **final_val,
mergeinfo with a start rev > end rev. If that gets into the
repository then a world of bustage breaks loose anytime that
bogus mergeinfo is parsed. See
- http://subversion.tigris.org/issues/show_bug.cgi?id=3020#desc16.
+ https://issues.apache.org/jira/browse/SVN-3020#desc16.
*/
continue;
}
@@ -377,7 +379,10 @@ make_node_baton(struct node_baton **node_baton_p,
/* Then add info from the headers. */
if ((val = svn_hash_gets(headers, SVN_REPOS_DUMPFILE_NODE_PATH)))
{
- val = svn_relpath_canonicalize(val, pool);
+ const char *canonicalized_path;
+ SVN_ERR(svn_relpath_canonicalize_safe(&canonicalized_path, NULL,
+ val, pool, pool));
+ val = canonicalized_path;
if (rb->pb->parent_dir)
nb->path = svn_relpath_join(rb->pb->parent_dir, val, pool);
else
@@ -1202,7 +1207,12 @@ svn_repos_get_fs_build_parser6(const svn_repos_parse_fns3_t **callbacks,
struct parse_baton *pb = apr_pcalloc(pool, sizeof(*pb));
if (parent_dir)
- parent_dir = svn_relpath_canonicalize(parent_dir, pool);
+ {
+ const char *canonicalized_path;
+ SVN_ERR(svn_relpath_canonicalize_safe(&canonicalized_path, NULL,
+ parent_dir, pool, pool));
+ parent_dir = canonicalized_path;
+ }
SVN_ERR_ASSERT((SVN_IS_VALID_REVNUM(start_rev) &&
SVN_IS_VALID_REVNUM(end_rev))