On Sep 2, 2005, at 7:51 PM, Ian Lynagh wrote:

On Fri, Sep 02, 2005 at 03:07:51PM -0700, Bill Trost wrote:


So, I propose that a binary patch consist of a sequence of the 5- tuple

    (old-start, old-length, new-start, new-length, bitmask)

Applying a binary patch consists of doing the following with each
5-tuple:

    1. Truncating or zero-extending the bitmask and source region so
    they are as long as the target region.

    2. XORing the bitmask and source region to generate the target
    region.


Sounds good to me. I think commuting with current binary patches is
possible, albeit slightly nasty.

We could also do
(old-start, old-length, new-start, new-length, old-content, new- content)
of course, but once you stop storing the complete file in each patch I
think having the actual content in the patch has very little advantage
over the bitmask idea.

Files can change back and forth in terms of "binary status". Will this be a problem? I don't think it will, but it's something to keep in mind.

Other than that one detail, I think this sounds great.

Jason


_______________________________________________
darcs-devel mailing list
[email protected]
http://www.abridgegame.org/cgi-bin/mailman/listinfo/darcs-devel

Reply via email to