GNU bug report logs - #16848
diff reports a diff on identical lines

Previous Next

Package: diffutils;

Reported by: Vincent Lefevre <vincent <at> vinc17.net>

Date: Sun, 23 Feb 2014 02:54:01 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 16848 in the body.
You can then email your comments to 16848 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-diffutils <at> gnu.org:
bug#16848; Package diffutils. (Sun, 23 Feb 2014 02:54:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Vincent Lefevre <vincent <at> vinc17.net>:
New bug report received and forwarded. Copy sent to bug-diffutils <at> gnu.org. (Sun, 23 Feb 2014 02:54:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Vincent Lefevre <vincent <at> vinc17.net>
To: bug-diffutils <at> gnu.org
Subject: diff reports a diff on identical lines
Date: Sun, 23 Feb 2014 03:52:48 +0100
[Message part 1 (text/plain, inline)]
On some pair of files, "diff" reports a diff on identical lines.
See the attached archive. At line 1272 of "diff -u out1 out2":

@@ -137681,90 +138934,186 @@
 26659
 468
 462
-26946
+26946
+470
+814
+815
[...]

This chunk shouldn't contain:

-26946
+26946

There's the same problem without the "-u" option.

-- 
Vincent Lefèvre <vincent <at> vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
[bug.tar.xz (application/octet-stream, attachment)]

Information forwarded to bug-diffutils <at> gnu.org:
bug#16848; Package diffutils. (Sun, 23 Feb 2014 02:57:02 GMT) Full text and rfc822 format available.

Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Vincent Lefevre <vincent <at> vinc17.net>
To: bug-diffutils <at> gnu.org
Subject: Re: diff reports a diff on identical lines
Date: Sun, 23 Feb 2014 03:55:44 +0100
On 2014-02-23 03:52:48 +0100, Vincent Lefevre wrote:
> On some pair of files, "diff" reports a diff on identical lines.
> See the attached archive. At line 1272 of "diff -u out1 out2":
[...]

I forgot: this happens with diff 3.3 under Debian/unstable.

-- 
Vincent Lefèvre <vincent <at> vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)




Information forwarded to bug-diffutils <at> gnu.org:
bug#16848; Package diffutils. (Sun, 23 Feb 2014 18:59:02 GMT) Full text and rfc822 format available.

Message #11 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Eric Deplagne <Eric <at> Deplagne.name>
To: bug-diffutils <at> gnu.org
Subject: Re: [bug-diffutils] bug#16848: diff reports a diff on identical lines
Date: Sun, 23 Feb 2014 07:24:31 +0100
[Message part 1 (text/plain, inline)]
On Sun, 23 Feb 2014 03:52:48 +0100, Vincent Lefevre wrote:
> On some pair of files, "diff" reports a diff on identical lines.
> See the attached archive. At line 1272 of "diff -u out1 out2":
> 
> @@ -137681,90 +138934,186 @@
>  26659
>  468
>  462
> -26946
> +26946
> +470
> +814
> +815
> [...]
> 
> This chunk shouldn't contain:
> 
> -26946
> +26946
> 
> There's the same problem without the "-u" option.

  Some whitespace diff ?

-- 
  Eric Deplagne
[signature.asc (application/pgp-signature, inline)]

Reply sent to Paul Eggert <eggert <at> cs.ucla.edu>:
You have taken responsibility. (Mon, 24 Feb 2014 07:00:03 GMT) Full text and rfc822 format available.

Notification sent to Vincent Lefevre <vincent <at> vinc17.net>:
bug acknowledged by developer. (Mon, 24 Feb 2014 07:00:05 GMT) Full text and rfc822 format available.

Message #16 received at 16848-done <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Vincent Lefevre <vincent <at> vinc17.net>, 16848-done <at> debbugs.gnu.org
Cc: Gnulib bugs <bug-gnulib <at> gnu.org>
Subject: Re: [bug-diffutils] bug#16848: diff reports a diff on identical lines
Date: Sun, 23 Feb 2014 22:59:40 -0800
[Message part 1 (text/plain, inline)]
Thanks for the bug report.

I applied the attached three patches; the first is to gnulib and changes 
gnulib's diffseq module to handle that case better, the second is to 
diffutils and brings diffutils up to the latest gnulib, and the third is 
also to diffutils and makes diffutils compatible with the new gnulib in 
order to use the fix.  I'll CC: this to bug-gnulib.  The fix works for 
me so I'm marking this bug as fixed, but if it still doesn't work for 
you I can reopen it.
[diffseq.patch (text/plain, attachment)]
[0001-build-update-gnulib-submodule-to-latest.patch (text/plain, attachment)]
[0002-diff-remove-TOO_EXPENSIVE-heuristic.patch (text/plain, attachment)]

Information forwarded to bug-diffutils <at> gnu.org:
bug#16848; Package diffutils. (Mon, 24 Feb 2014 19:33:02 GMT) Full text and rfc822 format available.

Message #19 received at 16848-done <at> debbugs.gnu.org (full text, mbox):

From: Jim Meyering <jim <at> meyering.net>
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: 16848-done <at> debbugs.gnu.org, Gnulib bugs <bug-gnulib <at> gnu.org>,
 Vincent Lefevre <vincent <at> vinc17.net>
Subject: Re: [bug-diffutils] bug#16848: diff reports a diff on identical lines
Date: Mon, 24 Feb 2014 11:31:38 -0800
On Sun, Feb 23, 2014 at 10:59 PM, Paul Eggert <eggert <at> cs.ucla.edu> wrote:
> Thanks for the bug report.
>
> I applied the attached three patches; the first is to gnulib and changes
> gnulib's diffseq module to handle that case better, the second is to
> diffutils and brings diffutils up to the latest gnulib, and the third is
> also to diffutils and makes diffutils compatible with the new gnulib in
> order to use the fix.  I'll CC: this to bug-gnulib.  The fix works for me so
> I'm marking this bug as fixed, but if it still doesn't work for you I can
> reopen it.

Great!  Thanks a lot, Paul.
If you find the time, would you please also add a test case like the
one Vincent posted?




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 25 Mar 2014 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 11 years and 146 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.