| CODENOTIFIER | HelpYou are not signed inSign in |
Project: Subversion
Revision: 32913
Author: julianfoad
Date: 05 Sep 2008 07:08:22
Changes:Allow 'svn merge' to merge diffs which add 'svn:eol-style' properties
to files that used to have inconsistent newlines.
This makes merge_tests.py 107 pass.
This is a follow-up to r30756 which did the same thing for some cases.
Patch by: glasser
me
* subversion/libsvn_wc/merge.c
(detranslate_wc_file): Repair newlines when translating 'left' file in a
merge. Add some comments about this.
(maybe_update_target_eols): Add similar comments for the case fixed by
r30756.
* subversion/tests/cmdline/merge_tests.py
(test_list): Remove 'XFail' from test 107, as it now passes.
| ... | ...@@ -12815,7 +12815,7 @@ | |
| 12815 | 12815 | SkipUnless(merge_target_and_subtrees_need_nonintersecting_ranges, |
| 12816 | 12816 | server_has_mergeinfo), |
| 12817 | 12817 | XFail(merge_two_edits_to_same_prop), |
| 12818 | XFail(merge_an_eol_unification_and_set_svn_eol_style), | |
| 12818 | merge_an_eol_unification_and_set_svn_eol_style, | |
| 12819 | 12819 | ] |
| 12820 | 12820 | |
| 12821 | 12821 | if __name__ == '__main__': |
| ... | ...@@ -205,10 +205,15 @@ | |
| 205 | 205 | svn_wc_adm_access_path(adm_access), |
| 206 | 206 | svn_io_file_del_none, pool)); |
| 207 | 207 | |
| 208 | /* Always 'repair' EOLs here, so that we can apply a diff that changes | |
| 209 | * from inconsistent newlines and no 'svn:eol-style' to consistent | |
| 210 | * newlines and 'svn:eol-style' set. */ | |
| 211 | ||
| 208 | 212 | SVN_ERR(svn_subst_translate_to_normal_form(merge_target, |
| 209 | 213 | detranslated, |
| 210 | 214 | style, |
| 211 | eol, eol ? FALSE : TRUE, | |
| 215 | eol, | |
| 216 | TRUE /* always_repair_eols */, | |
| 212 | 217 | keywords, |
| 213 | 218 | special, |
| 214 | 219 | pool)); |
| ... | ...@@ -243,9 +248,14 @@ | |
| 243 | 248 | svn_wc_adm_access_path(adm_access), |
| 244 | 249 | svn_io_file_del_none, |
| 245 | 250 | pool)); |
| 251 | ||
| 252 | /* Always 'repair' EOLs here, so that we can apply a diff that changes | |
| 253 | * from inconsistent newlines and no 'svn:eol-style' to consistent | |
| 254 | * newlines and 'svn:eol-style' set. */ | |
| 255 | ||
| 246 | 256 | SVN_ERR(svn_subst_copy_and_translate3(old_target, |
| 247 | 257 | tmp_new, |
| 248 | eol, TRUE, | |
| 258 | eol, TRUE /* repair EOLs */, | |
| 249 | 259 | NULL, FALSE, |
| 250 | 260 | FALSE, pool)); |
| 251 | 261 | *new_target = tmp_new; |