Re: [PATCH 5/8] rerere: use ll_merge() instead of using xdl_merge()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sonntag, 17. Januar 2010, Junio C Hamano wrote:
> This allows us to pay attention to the attribute settings and custom
> merge driver the user sets up.

I do not think that this change is necessary; I even think that it is wrong, 
in particular, custom merge drivers should *not* be used anymore.

The code path is about merging the changes between preimage and postimage into 
a file that has conflict markers (thisimage). At the time when this happens, 
all three images have already been processed by the custom merge driver.

Consider this preimage:

<foo><bar>
<<<<<<<
</bar>
=======
<baz>
text
</baz></bar>
>>>>>>>
<more text="here" />
</foo>

and a custom XML merge driver. With your change, you expect that the merge 
driver knows how to treat syntactically incorrect XML (the "<<<<<<<" 
and ">>>>>>>").

Of course, without this change, we do expect that the postimage has 
practically everything outside the conflict markers unchanged[*], otherwise 
the ll_merge() will fail.

But so would a custom XML driver that does not know how to read conflict 
markers.

[*] Which is perhaps an assumption that is easily violated. For example, the 
XML editor used to resolve the conflict could have inserted line-breaks at 
completely different spots than in the conflicted preimage.

-- Hannes
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]