bug-patch
[Top][All Lists]
Advanced

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

Re: [bug-patch] fuzz calculation change between patch 2.5.9 and 2.6


From: Mike Frysinger
Subject: Re: [bug-patch] fuzz calculation change between patch 2.5.9 and 2.6
Date: Mon, 23 Nov 2009 11:31:35 -0500
User-agent: KMail/1.12.3 (Linux/2.6.31.4; KDE/4.3.3; x86_64; ; )

On Monday 23 November 2009 10:45:05 Andreas Gruenbacher wrote:
> On Monday 23 November 2009 04:07:02 Mike Frysinger wrote:
> > and try to apply it:
> >     patch -p0 -F3 < diff
> >
> > with patch-2.5.9 and older, you'll get an error (since the files in
> > question are missing).  with patch-2.6, the patch will "apply".
> 
> The patch has three lines of context and with -F3, up to three lines of
> context are ignored.  The result will be rather random, but I think it
>  could be argued that based on the line numbers, patch should assume that
>  the files must exist.

yes, i'm not saying the application method is sane (i plan on having the code 
using this changed), but i dont think the patch should have succeeded in this 
case since there are lines matching but the files dont exist

the man page is a bit unclear in the -F description:
        Set the maximum fuzz factor.  This option only applies to diffs that 
have
        context, and causes patch to ignore up to that many lines in looking for
        places to install a hunk.
i think the "that many lines" should be followed by "of context".  otherwise, 
if we consider the current patch, it has 6 lines of the source which is 
certainly less than -F3.
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]