* branches/issue-531-dev/subversion: Merged -r2699:2702 changes from /trunk/subversion. * subversion/libsvn_fs/reps-strings.c (APR_ARRAY_IDX): Remove duplicate definition. git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/issue-531-dev@842777 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/subversion/libsvn_client/add.c b/subversion/libsvn_client/add.c index 7ab37b5..44b1d9e 100644 --- a/subversion/libsvn_client/add.c +++ b/subversion/libsvn_client/add.c
@@ -189,6 +189,7 @@ /* Split the new directory name from its parent URL. */ svn_path_split_nts (path, &anchor, &target, pool); + target = svn_path_uri_decode (target, pool); /* Get the RA vtable that matches URL. */ SVN_ERR (svn_ra_init_ra_libs (&ra_baton, pool));
diff --git a/subversion/libsvn_client/copy.c b/subversion/libsvn_client/copy.c index d9648da..70513a7 100644 --- a/subversion/libsvn_client/copy.c +++ b/subversion/libsvn_client/copy.c
@@ -164,6 +164,7 @@ src_rel = svn_path_is_child (top_url, src_url, pool); if (src_rel) { + src_rel = svn_path_uri_decode (src_rel, pool); src_pieces = svn_path_decompose (src_rel, pool); if ((! src_pieces) || (! src_pieces->nelts)) return svn_error_createf @@ -174,6 +175,7 @@ dst_rel = svn_path_is_child (top_url, dst_url, pool); if (dst_rel) { + dst_rel = svn_path_uri_decode (dst_rel, pool); dst_pieces = svn_path_decompose (dst_rel, pool); if ((! dst_pieces) || (! dst_pieces->nelts)) return svn_error_createf @@ -236,18 +238,17 @@ pre-existing directory. So we temporarily append src_url's basename to dst_rel, and see if that already exists. */ svn_node_kind_t some_kind; - const char *hypothetical_repos_path = - svn_path_join (dst_rel, svn_path_basename (src_url, pool), pool); - + const char *hypothetical_repos_path; + + base_name = svn_path_basename (src_url, pool); + hypothetical_repos_path + = svn_path_join (dst_rel, svn_path_uri_decode (base_name, pool), pool); SVN_ERR (ra_lib->check_path (&some_kind, sess, hypothetical_repos_path, youngest)); if (some_kind != svn_node_none) return svn_error_createf (SVN_ERR_FS_ALREADY_EXISTS, 0, NULL, pool, "fs path `%s' already exists.", hypothetical_repos_path); - - /* Normal case: we'll put the src basename into the dst directory. */ - svn_path_split_nts (src_url, &unused, &base_name, pool); } else { @@ -281,9 +282,7 @@ while (i < dst_pieces->nelts) { piece = (((const char **)(dst_pieces)->elts)[i]); - telepath = svn_path_join (telepath, - svn_path_uri_decode (piece, pool), - pool); + telepath = svn_path_join (telepath, piece, pool); SVN_ERR (editor->open_directory (telepath, batons[i], youngest, pool, &(batons[i + 1]))); i++; @@ -327,9 +326,7 @@ while (i < (src_pieces->nelts - 1)) { piece = (((const char **)(src_pieces)->elts)[i]); - telepath = svn_path_join (telepath, - svn_path_uri_decode (piece, pool), - pool); + telepath = svn_path_join (telepath, piece, pool); SVN_ERR (editor->open_directory (telepath, batons[i], youngest, pool, &(batons[i + 1]))); i++; @@ -337,9 +334,7 @@ /* Delete SRC. */ piece = (((const char **)(src_pieces)->elts)[i]); - telepath = svn_path_join (telepath, - svn_path_uri_decode (piece, pool), - pool); + telepath = svn_path_join (telepath, piece, pool); SVN_ERR (editor->delete_entry (telepath, SVN_INVALID_REVNUM, batons[i], pool)); @@ -521,7 +516,8 @@ auth_baton, pool)); /* Figure out the basename that will result from this operation. */ - SVN_ERR (ra_lib->check_path (&dst_kind, session, target, + SVN_ERR (ra_lib->check_path (&dst_kind, session, + svn_path_uri_decode (target, pool), SVN_INVALID_REVNUM)); /* Close the RA session. We'll re-open it after we've figured out @@ -540,9 +536,7 @@ { /* DST_URL is an existing directory URL. The URL we will be creating, then, is DST_URL+BASENAME. */ - base_url = svn_path_join (base_url, - svn_path_uri_encode (base_name, pool), - pool); + base_url = svn_path_url_add_component (base_url, base_name, pool); } else {
diff --git a/subversion/libsvn_client/delete.c b/subversion/libsvn_client/delete.c index 97866e0..272961d 100644 --- a/subversion/libsvn_client/delete.c +++ b/subversion/libsvn_client/delete.c
@@ -126,6 +126,7 @@ log_msg = ""; svn_path_split_nts (path, &anchor, &target, pool); + target = svn_path_uri_decode (target, pool); /* Get the RA vtable that matches URL. */ SVN_ERR (svn_ra_init_ra_libs (&ra_baton, pool));
diff --git a/subversion/libsvn_client/switch.c b/subversion/libsvn_client/switch.c index fe4b17b..a455113 100644 --- a/subversion/libsvn_client/switch.c +++ b/subversion/libsvn_client/switch.c
@@ -174,12 +174,11 @@ /* We handle externals after the switch is complete, so that handling external items (and any errors therefrom) doesn't delay the primary operation. */ - SVN_ERR (svn_client__handle_externals - (traversal_info, - notify_func, notify_baton, - auth_baton, - FALSE, - pool)); + SVN_ERR (svn_client__handle_externals (traversal_info, + notify_func, notify_baton, + auth_baton, + FALSE, + pool)); } else if (entry->kind == svn_node_file)
diff --git a/subversion/libsvn_fs/reps-strings.c b/subversion/libsvn_fs/reps-strings.c index 3b81c16..34b0121 100644 --- a/subversion/libsvn_fs/reps-strings.c +++ b/subversion/libsvn_fs/reps-strings.c
@@ -34,7 +34,6 @@ /*** Local prototypes. ***/ -#define APR_ARRAY_IDX(ary,i,type) (((type *)(ary)->elts)[i]) static svn_error_t *rep_read_range (svn_fs_t *fs, const char *rep_key,
diff --git a/subversion/libsvn_ra_dav/props.c b/subversion/libsvn_ra_dav/props.c index d05373d..b6f9140 100644 --- a/subversion/libsvn_ra_dav/props.c +++ b/subversion/libsvn_ra_dav/props.c
@@ -675,7 +675,8 @@ if (is_dir != NULL) { /* query the DAV:resourcetype of the full, assembled URL. */ - const char *full_bc_url = svn_path_join(my_bc_url, my_bc_relative, pool); + const char *full_bc_url + = svn_path_url_add_component(my_bc_url, my_bc_relative, pool); SVN_ERR( svn_ra_dav__get_props_resource(&rsrc, sess, full_bc_url, NULL, starting_props, pool) ); *is_dir = rsrc->is_collection;
diff --git a/subversion/libsvn_wc/adm_ops.c b/subversion/libsvn_wc/adm_ops.c index a23f034..7b72651 100644 --- a/subversion/libsvn_wc/adm_ops.c +++ b/subversion/libsvn_wc/adm_ops.c
@@ -86,7 +86,7 @@ /* Derive the new URL for the current (child) entry */ if (base_url) - child_url = svn_path_join (base_url, name, subpool); + child_url = svn_path_url_add_component (base_url, name, subpool); /* If a file (or deleted dir), tweak the entry. */ if ((current_entry->kind == svn_node_file)