You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by hw...@apache.org on 2011/07/29 17:20:56 UTC
svn commit: r1152261 - in /subversion/branches/1.7.x: ./ STATUS
subversion/libsvn_wc/adm_ops.c subversion/tests/cmdline/special_tests.py
Author: hwright
Date: Fri Jul 29 15:20:55 2011
New Revision: 1152261
URL: http://svn.apache.org/viewvc?rev=1152261&view=rev
Log:
Merge r1150812 from trunk:
* r1150812
Issue 3972, spurious revert notification on symlinks
Justification:
A regression from 1.6.
Votes:
+1: philip, stsp, danielsh
Modified:
subversion/branches/1.7.x/ (props changed)
subversion/branches/1.7.x/STATUS
subversion/branches/1.7.x/subversion/libsvn_wc/adm_ops.c
subversion/branches/1.7.x/subversion/tests/cmdline/special_tests.py
Propchange: subversion/branches/1.7.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Jul 29 15:20:55 2011
@@ -54,4 +54,4 @@
/subversion/branches/tree-conflicts:868291-873154
/subversion/branches/tree-conflicts-notify:873926-874008
/subversion/branches/uris-as-urls:1060426-1064427
-/subversion/trunk:1146013,1146121,1146219,1146222,1146274,1146492,1146555,1146606,1146620,1146684,1146781,1146832,1146834,1146870,1146899,1146904,1147293,1147309,1147882,1148071,1148131,1148374,1148424,1148566,1148588,1148853,1148877,1148882,1148936,1149105,1149141,1149160,1149228,1149240,1149343,1149371-1149372,1149377,1149398,1149572,1149675,1149701,1149713,1150372,1151036,1152129
+/subversion/trunk:1146013,1146121,1146219,1146222,1146274,1146492,1146555,1146606,1146620,1146684,1146781,1146832,1146834,1146870,1146899,1146904,1147293,1147309,1147882,1148071,1148131,1148374,1148424,1148566,1148588,1148853,1148877,1148882,1148936,1149105,1149141,1149160,1149228,1149240,1149343,1149371-1149372,1149377,1149398,1149572,1149675,1149701,1149713,1150372,1150812,1151036,1152129
Modified: subversion/branches/1.7.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/STATUS?rev=1152261&r1=1152260&r2=1152261&view=diff
==============================================================================
--- subversion/branches/1.7.x/STATUS (original)
+++ subversion/branches/1.7.x/STATUS Fri Jul 29 15:20:55 2011
@@ -219,10 +219,3 @@ Approved changes:
this revision depends for a clean merge).
Votes:
+1: rhuijben, danielsh, cmpilato
-
- * r1150812
- Issue 3972, spurious revert notification on symlinks
- Justification:
- A regression from 1.6.
- Votes:
- +1: philip, stsp, danielsh
Modified: subversion/branches/1.7.x/subversion/libsvn_wc/adm_ops.c
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/subversion/libsvn_wc/adm_ops.c?rev=1152261&r1=1152260&r2=1152261&view=diff
==============================================================================
--- subversion/branches/1.7.x/subversion/libsvn_wc/adm_ops.c (original)
+++ subversion/branches/1.7.x/subversion/libsvn_wc/adm_ops.c Fri Jul 29 15:20:55 2011
@@ -1389,8 +1389,6 @@ revert_restore(svn_wc__db_t *db,
else if (on_disk == svn_node_file)
{
svn_boolean_t modified;
- svn_boolean_t executable;
- svn_boolean_t read_only;
apr_hash_t *props;
#ifdef HAVE_SYMLINK
svn_string_t *special_prop;
@@ -1438,11 +1436,6 @@ revert_restore(svn_wc__db_t *db,
db, local_abspath,
TRUE, scratch_pool));
- SVN_ERR(svn_io__is_finfo_executable(&executable, &finfo,
- scratch_pool));
- SVN_ERR(svn_io__is_finfo_read_only(&read_only, &finfo,
- scratch_pool));
-
if (modified)
{
SVN_ERR(svn_io_remove_file2(local_abspath, FALSE,
@@ -1451,10 +1444,12 @@ revert_restore(svn_wc__db_t *db,
}
else
{
+ svn_boolean_t read_only;
svn_string_t *needs_lock_prop;
-#if !defined(WIN32) && !defined(__OS2__)
- svn_string_t *executable_prop;
-#endif
+
+ SVN_ERR(svn_io__is_finfo_read_only(&read_only, &finfo,
+ scratch_pool));
+
needs_lock_prop = apr_hash_get(props, SVN_PROP_NEEDS_LOCK,
APR_HASH_KEY_STRING);
if (needs_lock_prop && !read_only)
@@ -1471,19 +1466,31 @@ revert_restore(svn_wc__db_t *db,
}
#if !defined(WIN32) && !defined(__OS2__)
- executable_prop = apr_hash_get(props, SVN_PROP_EXECUTABLE,
- APR_HASH_KEY_STRING);
- if (executable_prop && !executable)
- {
- SVN_ERR(svn_io_set_file_executable(local_abspath, TRUE,
- FALSE, scratch_pool));
- notify_required = TRUE;
- }
- else if (!executable_prop && executable)
+#ifdef HAVE_SYMLINK
+ if (!special)
+#endif
{
- SVN_ERR(svn_io_set_file_executable(local_abspath, FALSE,
- FALSE, scratch_pool));
- notify_required = TRUE;
+ svn_boolean_t executable;
+ svn_string_t *executable_prop;
+
+ SVN_ERR(svn_io__is_finfo_executable(&executable, &finfo,
+ scratch_pool));
+ executable_prop = apr_hash_get(props, SVN_PROP_EXECUTABLE,
+ APR_HASH_KEY_STRING);
+ if (executable_prop && !executable)
+ {
+ SVN_ERR(svn_io_set_file_executable(local_abspath,
+ TRUE, FALSE,
+ scratch_pool));
+ notify_required = TRUE;
+ }
+ else if (!executable_prop && executable)
+ {
+ SVN_ERR(svn_io_set_file_executable(local_abspath,
+ FALSE, FALSE,
+ scratch_pool));
+ notify_required = TRUE;
+ }
}
#endif
}
Modified: subversion/branches/1.7.x/subversion/tests/cmdline/special_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/1.7.x/subversion/tests/cmdline/special_tests.py?rev=1152261&r1=1152260&r2=1152261&view=diff
==============================================================================
--- subversion/branches/1.7.x/subversion/tests/cmdline/special_tests.py (original)
+++ subversion/branches/1.7.x/subversion/tests/cmdline/special_tests.py Fri Jul 29 15:20:55 2011
@@ -711,6 +711,7 @@ def unrelated_changed_special_status(sbo
'-m', 'psi changed special status')
+@Issue(3972)
@SkipUnless(svntest.main.is_posix_os)
def symlink_destination_change(sbox):
"revert a symlink destination change"
@@ -747,6 +748,10 @@ def symlink_destination_change(sbox):
expected_status.tweak('newfile', status=' ')
svntest.actions.run_and_verify_status(wc_dir, expected_status)
+ # Issue 3972, repeat revert produces no output
+ svntest.actions.run_and_verify_svn(None, [], [], 'revert', '-R', wc_dir)
+ svntest.actions.run_and_verify_status(wc_dir, expected_status)
+
# Now replace the symlink with a normal file and try to commit, we
#----------------------------------------------------------------------