You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ko...@apache.org on 2015/09/11 15:53:40 UTC
svn commit: r1702467 - in /subversion/trunk/subversion: libsvn_client/mtcc.c
tests/cmdline/svnmucc_tests.py
Author: kotkov
Date: Fri Sep 11 13:53:39 2015
New Revision: 1702467
URL: http://svn.apache.org/r1702467
Log:
Unbreak svnmucc propset + put action sequences executed for the same
existing file:
svnmucc propset p v target put src target
svnmucc: E160013: Can't open 'target' as it does not exist
There's a bug in svn_client__mtcc_check_path() implementation that doesn't
handle svn_node_file after determining the kind of a remote path. As a
consequence, sometimes existing files were treated as non-existing and
that was triggering the error.
* subversion/libsvn_client/mtcc.c
(svn_client__mtcc_check_path): Correct the condition so that it would
handle svn_node_file kinds.
* subversion/tests/cmdline/svnmucc_tests.py
(basic_svnmucc): Extend this test with another case; fails without
the fix.
Modified:
subversion/trunk/subversion/libsvn_client/mtcc.c
subversion/trunk/subversion/tests/cmdline/svnmucc_tests.py
Modified: subversion/trunk/subversion/libsvn_client/mtcc.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/mtcc.c?rev=1702467&r1=1702466&r2=1702467&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/mtcc.c (original)
+++ subversion/trunk/subversion/libsvn_client/mtcc.c Fri Sep 11 13:53:39 2015
@@ -981,7 +981,7 @@ svn_client__mtcc_check_path(svn_node_kin
"on '%s' as it is not a directory"),
relpath);
}
- else if (op && *kind == svn_node_dir)
+ else if (op && *kind == svn_node_file)
{
if (op->kind == OP_OPEN_FILE || op->kind == OP_ADD_FILE)
op->performed_stat = TRUE;
Modified: subversion/trunk/subversion/tests/cmdline/svnmucc_tests.py
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/svnmucc_tests.py?rev=1702467&r1=1702466&r2=1702467&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/svnmucc_tests.py (original)
+++ subversion/trunk/subversion/tests/cmdline/svnmucc_tests.py Fri Sep 11 13:53:39 2015
@@ -106,7 +106,9 @@ def basic_svnmucc(sbox):
sbox.build()
empty_file = sbox.ospath('empty')
+ file = sbox.ospath('file')
svntest.main.file_append(empty_file, '')
+ svntest.main.file_append(file, 'file')
# revision 2
test_svnmucc(sbox.repo_url,
@@ -301,6 +303,14 @@ def basic_svnmucc(sbox):
'propsetf', 'testprop', empty_file, 'foo/z.c',
'propsetf', 'testprop', empty_file, 'foo/foo')
+ # revision 21
+ test_svnmucc(sbox.repo_url,
+ ['M /foo/z.c',
+ ], #---------
+ '-m', 'log msg',
+ 'propset', 'testprop', 'false', 'foo/z.c',
+ 'put', file, 'foo/z.c')
+
# Expected missing revision error
xtest_svnmucc(sbox.repo_url,
["svnmucc: E200004: 'a' is not a revision"