[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Merge bug(let)

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2003-02-26 14:04:19 CET

"Sander Striker" <striker@apache.org> writes:

> > From: Philip Martin
> > Sent: Tuesday, February 25, 2003 9:03 PM
>
> > "Sander Striker" <striker@apache.org> writes:
> >
> >> Upon investigation of subversion/libsvn_wc/merge.c I saw that we are
> >> trying to merge 3 conflicting files and then we leave 3 non
> >> conflicting files in the wc. The reason the 3 files we try to merge
> >> conflict is because we aren't doing eol translation prior to running
> >> merge (is my guess). We are doing that _after_ we see the conflict.
> >
> > Yes, at present merge occurs using all three files in
> > repository-normal form, which involves translating the working copy
> > file to repository-normal form before merging.
>
> Well, something is definately not working right, since I would expect
> a clean merge when all files are in repos normal form.

Is it possible that the svn:eol-style property is getting merged
before the text? That would explain the conflict as follows. Both
the working copy and the old merge source have no svn:eol-style and
CRLF line endings, the new merge source has native svn:eol-style and
LF line endings. The difference between the two merge sources removes
some trailing whitespace as well as changing line endings. If the
svn:eol-style gets merged first then when the text comes to get merged
the working copy will get detranslated from CRLF to LF. Thus every
line will be different from the old merge source and so any change
between the working copy and the new merge source will be a conflict.
The removal of trailing whitespace thus causes the conflict.

> > Note that the three files could each have svn:eol-style set to a
> > different value.
>
> Hmpf, yes, that would be a problem.
>
> > Would you use the the setting appropriate for each
> > file or would you pick one, the working copy most probably, and use
> > that for all the files?
>
> And that sounds like a viable solution ;)

Given my analysis above, I think the setting for the new merge source
might be better. Tricky stuff this eol-conversion...

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Feb 26 14:05:02 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.