You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2013/01/26 18:43:50 UTC
svn commit: r1438924 -
/subversion/trunk/subversion/libsvn_client/repos_diff.c
Author: rhuijben
Date: Sat Jan 26 17:43:50 2013
New Revision: 1438924
URL: http://svn.apache.org/viewvc?rev=1438924&view=rev
Log:
* subversion/libsvn_client/repos_diff.c
(diff_state_handle): Following up on r1438922, really extract the
obstruction cases by reading the right property. Remove obstruction
and tree conflict conditionals from old code.
Modified:
subversion/trunk/subversion/libsvn_client/repos_diff.c
Modified: subversion/trunk/subversion/libsvn_client/repos_diff.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/repos_diff.c?rev=1438924&r1=1438923&r2=1438924&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/repos_diff.c (original)
+++ subversion/trunk/subversion/libsvn_client/repos_diff.c Sat Jan 26 17:43:50 2013
@@ -1424,8 +1424,8 @@ diff_state_handle(svn_boolean_t tree_con
notify_content_state = notify_prop_state;
}
- if (notify_prop_state == svn_wc_notify_state_obstructed
- || notify_prop_state == svn_wc_notify_state_missing)
+ if (notify_content_state == svn_wc_notify_state_obstructed
+ || notify_content_state == svn_wc_notify_state_missing)
{
svn_wc_notify_t *notify;
@@ -1439,8 +1439,6 @@ diff_state_handle(svn_boolean_t tree_con
return SVN_NO_ERROR;
}
-
-
/* This code is copy & pasted from different functions in this file.
It is only used from the merge api, and should really be integrated
there.
@@ -1457,7 +1455,7 @@ diff_state_handle(svn_boolean_t tree_con
* still around. */
dpn = apr_hash_get(eb->deleted_paths, relpath, APR_HASH_KEY_STRING);
if (dpn)
- {
+ {
/* If any was found, we will handle the pending 'deleted path
* notification' (DPN) here. Remove it from the list. */
apr_hash_set(eb->deleted_paths, relpath,
@@ -1466,24 +1464,19 @@ diff_state_handle(svn_boolean_t tree_con
/* the pending delete might be on a different node kind. */
kind = dpn->kind;
*state = *prop_state = dpn->state;
- }
+ }
/* Determine what the notification (ACTION) should be.
* In case of a pending 'delete', this might become a 'replace'. */
- if (tree_conflicted)
- action = svn_wc_notify_tree_conflict;
- else if (dpn)
- {
- if (dpn->action == svn_wc_notify_update_delete
- && for_add)
- action = svn_wc_notify_update_replace;
- else
- /* Note: dpn->action might be svn_wc_notify_tree_conflict */
- action = dpn->action;
- }
- else if ((*state == svn_wc_notify_state_missing)
- || (*state == svn_wc_notify_state_obstructed))
- action = svn_wc_notify_skip;
+ if (dpn)
+ {
+ if (dpn->action == svn_wc_notify_update_delete
+ && for_add)
+ action = svn_wc_notify_update_replace;
+ else
+ /* Note: dpn->action might be svn_wc_notify_tree_conflict */
+ action = dpn->action;
+ }
else if (for_add)
action = svn_wc_notify_update_add;
else
@@ -1509,9 +1502,6 @@ diff_state_handle(svn_boolean_t tree_con
svn_wc_notify_action_t action;
svn_node_kind_t kind = svn_node_dir;
- if (!before_operation && !tree_conflicted)
- return SVN_NO_ERROR;
-
/* Find out if a pending delete notification for this path is
* still around. */
dpn = apr_hash_get(eb->deleted_paths, relpath, APR_HASH_KEY_STRING);
@@ -1529,9 +1519,7 @@ diff_state_handle(svn_boolean_t tree_con
/* Determine what the notification (ACTION) should be.
* In case of a pending 'delete', this might become a 'replace'. */
- if (tree_conflicted)
- action = svn_wc_notify_tree_conflict;
- else if (dpn)
+ if (dpn)
{
if (dpn->action == svn_wc_notify_update_delete)
action = svn_wc_notify_update_replace;
@@ -1539,12 +1527,6 @@ diff_state_handle(svn_boolean_t tree_con
/* Note: dpn->action might be svn_wc_notify_tree_conflict */
action = dpn->action;
}
- else if (state
- && (*state == svn_wc_notify_state_missing
- || *state == svn_wc_notify_state_obstructed))
- {
- action = svn_wc_notify_skip;
- }
else
action = svn_wc_notify_update_add;
@@ -1562,21 +1544,8 @@ diff_state_handle(svn_boolean_t tree_con
content_state = state ? *state : svn_wc_notify_state_inapplicable;
- if (tree_conflicted)
- action = svn_wc_notify_tree_conflict;
- else
- action = svn_wc_notify_update_update;
-
- if (prop_state
- && (*prop_state == svn_wc_notify_state_obstructed
- || *prop_state == svn_wc_notify_state_missing))
- {
- content_state = *prop_state;
- if (action == svn_wc_notify_update_update)
- action = svn_wc_notify_skip;
- }
+ action = svn_wc_notify_update_update;
-
/* Dir modified */
notify = svn_wc_create_notify(relpath, action, scratch_pool);