Hi,
please find attached patch which fixes issue 2533.
The problem was that when remote propchanges are reported back to the
client, they are stored as status changed of the parent folder (see line
1589@close_directory@libsvn_wc/status.c). In the case of the root folder
there is no parent folder, so propchanges are silently dropped.
This patch will report remote propchanges on the root folder as status
changes of that root folder.
It slightly overlaps with my patch for issue #2468 which I sent to the
dev list a few days ago:
http://svn.haxx.se/dev/archive-2006-09/0809.shtml
regards,
Lieven.
[[[
Fix for issue #2533: fix status -u so it also shows remotely changed
properties on the root of our working copy.
* subversion/libsvn_wc/status.c
(close_directory): store remote propchanges on the root of our working
copy as status changes of that root folder.
(tweak_statushash): skip the test for issue #2122 on the root folder.
Use adm_access to create statusstruct.
* subversion/tests/cmdline/stat_tests.py
(status_update_with_incoming_props): put the expected output of
status -u in the correct order.
(test_list): This test is passing now, so remove the XFail wrapper.
]]]
Index: subversion/libsvn_wc/status.c
===================================================================
--- subversion/libsvn_wc/status.c (revision 21621)
+++ subversion/libsvn_wc/status.c (working copy)
@@ -1039,12 +1039,17 @@
correctly in the first, that path would either be mentioned
as an 'add' or not mentioned at all, depending on how we
eventually fix the bugs in non-recursivity. See issue
- #2122 for details. */
- if (repos_text_status != svn_wc_status_added)
- return SVN_NO_ERROR;
+ #2122 for details.
+ Note: skip the test if this is the root folder of our working
+ copy. It means some of the properties were changed remotely.
+ */
+ if (is_dir_baton && ((struct dir_baton *)baton)->parent_baton)
+ if (repos_text_status != svn_wc_status_added)
+ return SVN_NO_ERROR;
+
/* Use the public API to get a statstruct, and put it into the hash. */
- SVN_ERR(svn_wc_status2(&statstruct, path, NULL, pool));
+ SVN_ERR(svn_wc_status2(&statstruct, path, adm_access, pool));
statstruct->repos_lock = repos_lock;
apr_hash_set(statushash, apr_pstrdup(pool, path),
APR_HASH_KEY_STRING, statstruct);
@@ -1589,6 +1594,14 @@
db->path, TRUE,
repos_text_status,
repos_prop_status, NULL));
+ else
+ /* This is the root folder of the working copy and some of its
+ properties were changed in the repository */
+ SVN_ERR(tweak_statushash(db, TRUE,
+ eb->adm_access,
+ db->path, TRUE,
+ repos_text_status,
+ repos_prop_status, NULL));
}
/* Handle this directory's statuses, and then note in the parent
Index: subversion/tests/cmdline/stat_tests.py
===================================================================
--- subversion/tests/cmdline/stat_tests.py (revision 21621)
+++ subversion/tests/cmdline/stat_tests.py (working copy)
@@ -1053,8 +1053,8 @@
# Can't use run_and_verify_status here because the out-of-date
# information in the status output isn't copied in the status tree.
- xout = [" * 1 " + wc_dir + "\n",
- " * 1 " + os.path.join(wc_dir, "A") + "\n",
+ xout = [" * 1 " + A_path + "\n",
+ " * 1 " + wc_dir + "\n",
"Status against revision: 2\n" ]
svntest.actions.run_and_verify_svn(None,
@@ -1140,7 +1140,7 @@
XFail(status_nonrecursive_update_different_cwd),
status_add_plus_conflict,
inconsistent_eol,
- XFail(status_update_with_incoming_props),
+ status_update_with_incoming_props,
XFail(status_nonrecursive_update),
]
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Sep 24 13:56:15 2006