You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ju...@apache.org on 2011/05/09 12:13:40 UTC
svn commit: r1100942 - /subversion/trunk/subversion/libsvn_wc/update_editor.c
Author: julianfoad
Date: Mon May 9 10:13:40 2011
New Revision: 1100942
URL: http://svn.apache.org/viewvc?rev=1100942&view=rev
Log:
Simplify some code.
* subversion/libsvn_wc/update_editor.c
(create_tree_conflict): Assert that the 'their_relpath' parameter is
non-null, as it always is now. Remove temporary code to handle null.
(check_tree_conflict): Assert that 'their_relpath' is null, as above.
Modified:
subversion/trunk/subversion/libsvn_wc/update_editor.c
Modified: subversion/trunk/subversion/libsvn_wc/update_editor.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/update_editor.c?rev=1100942&r1=1100941&r2=1100942&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/update_editor.c (original)
+++ subversion/trunk/subversion/libsvn_wc/update_editor.c Mon May 9 10:13:40 2011
@@ -1139,6 +1139,7 @@ create_tree_conflict(svn_wc_conflict_des
*pconflict = NULL;
SVN_ERR_ASSERT(reason != SVN_WC_CONFLICT_REASON_NONE);
+ SVN_ERR_ASSERT(their_relpath != NULL);
/* Get the source-left information, i.e. the local state of the node
* before any changes were made to the working copy, i.e. the state the
@@ -1227,23 +1228,8 @@ create_tree_conflict(svn_wc_conflict_des
* to which we would like to update. */
if (eb->switch_relpath)
{
- /* If this is a 'switch' operation, try to construct the switch
- * target's REPOS_RELPATH. */
- if (their_relpath != NULL)
- right_repos_relpath = their_relpath;
- else
- {
- /* The complete source-right URL is not available, but it
- * is somewhere below the SWITCH_URL. For now, just go
- * without it.
- * ### TODO: Construct a proper THEIR_URL in some of the
- * delete cases that still pass NULL for THEIR_URL when
- * calling this function. Do that on the caller's side. */
- right_repos_relpath = eb->switch_relpath;
- right_repos_relpath = apr_pstrcat(result_pool, right_repos_relpath,
- "_THIS_IS_INCOMPLETE",
- (char *)NULL);
- }
+ /* This is a 'switch' operation. */
+ right_repos_relpath = their_relpath;
}
else
{
@@ -1343,6 +1329,8 @@ check_tree_conflict(svn_wc_conflict_desc
svn_boolean_t modified = FALSE;
svn_boolean_t all_mods_are_deletes = FALSE;
+ SVN_ERR_ASSERT(their_relpath != NULL);
+
*pconflict = NULL;
/* Find out if there are any local changes to this node that may