Please find attached patch for issue 3826. All tests pass using 'make check'
Log [[[ Fix for issue 3826. Make svn diff respect absolute paths. Also fix corresponding test. * subversion/svn/diff-cmd.c (svn_cl__diff): Do not convert absolute path into relative one. * subversion/tests/cmdline/diff_tests.py (diff_abs_localpath_from_wc_folder): Fix test to use correct absolute path. Remove XFail marker. Patch by: Noorul Islam K M <noorul{_AT_}collab.net> Found by: danielsh ]]]
Index: subversion/tests/cmdline/diff_tests.py =================================================================== --- subversion/tests/cmdline/diff_tests.py (revision 1076214) +++ subversion/tests/cmdline/diff_tests.py (working copy) @@ -3761,7 +3761,6 @@ '-c2', '--git') os.chdir(was_cwd) -@XFail() @Issue(3826) def diff_abs_localpath_from_wc_folder(sbox): "diff absolute localpath from wc folder" @@ -3770,9 +3769,10 @@ A_path = os.path.join(wc_dir, 'A') B_path = os.path.join(wc_dir, 'A', 'B') + B_abspath = os.path.abspath(B_path) os.chdir(os.path.abspath(A_path)) svntest.actions.run_and_verify_svn(None, None, [], 'diff', - os.path.abspath(B_path)) + B_abspath) ######################################################################## #Run the tests Index: subversion/svn/diff-cmd.c =================================================================== --- subversion/svn/diff-cmd.c (revision 1076214) +++ subversion/svn/diff-cmd.c (working copy) @@ -324,8 +324,11 @@ return svn_error_createf(SVN_ERR_CL_ARG_PARSING_ERROR, NULL, _("Path '%s' not relative to base URLs"), path); + if (! svn_dirent_is_absolute(path)) + path = svn_relpath_canonicalize(path, iterpool); + else + path = svn_dirent_canonicalize(path, iterpool); - path = svn_relpath_canonicalize(path, iterpool); if (svn_path_is_url(old_target)) target1 = svn_path_url_add_component2(old_target, path, iterpool); else