Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!spool.mu.edu!uunet!mdisea!mitchell From: mitchell@MDI.COM (Bill Mitchell) Newsgroups: comp.os.minix Subject: Re: Trouble with AM - a solution ? Message-ID: <1991May25.144403.318@MDI.COM> Date: 25 May 91 14:44:03 GMT Article-I.D.: MDI.1991May25.144403.318 References: <1991May23.132757.13578@Arco.COM> <1991May24.184035.21247@Arco.COM> Organization: Motorola, Mobile Data Division - Seattle, WA Lines: 44 In article <1991May24.184035.21247@Arco.COM> dprrhb@inetg1.ARCO.COM (Reginald H. Beardsley) writes: >In article , klamer@mi.eltn.utwente.nl (Klamer Schutte) writes: >> In <1991May23.132757.13578@Arco.COM> dprrhb@inetg1.ARCO.COM (Reginald H. Beardsley) writes: > >[text deleted] > >> This won't work. >> 1) When the cdiff is as big as the whole file it is likely to be rewritten >> completely. Why not send the new file in that case? > >This is the source of the problem with Fred's stuff. It's what we need to fix. > Seems it should be workable to define and use an alternative patch file format something like the following: 1. CRC of the file to be patched. Don't patch it unless the CRCs match User must have an exact copy of the file-to-be-patched. 2. list of ranges of lines to be deleted from the original file something like "1,4,7-96,112" this would include all lines which the changes either delete or modify 3. line number in the resulting file after which an insertion is to be made use a line number of zero to insert at the head of the file 4. count of lines to be inserted at that point 5. the lines of text to be inserted at that point 6. zero or more repetitions of items 3 thru 5 7. CRC of patched file (as a doublecheck) Seems this file ought to be free of copyrighted information from the original file. Seems it shouldn't be too tough to implement a program to convert diffs and cdiffs into this format, and to write a program to use patch information in this format to patch files. -- mitchell@mdi.com (Bill Mitchell)