Bug #381

diff is dropping first character from filenames in recursive diffs

Added by Ted Trask almost 4 years ago. Updated over 3 years ago.

Status:ClosedStart date:07/08/2010
Priority:NormalDue date:
Assignee:Natanael Copa% Done:

100%

Category:Aports
Target version:Alpine 1.10.7
Affected versions:

Description

Running 1.10.6 with latest from online repositories. I can do a direct copy of a directory, and a "diff -r" shows every filename as different. This happens both on a mounted lvm volume and in the RAM filesystem.

t:~/work# mkdir test
t:~/work# touch test/test1
t:~/work# touch test/test2
t:~/work# touch test/test3
t:~/work# cp -r test/ test2
t:~/work# diff -r test test2/
Only in test2/: est1
Only in test2/: est2
Only in test2/: est3
Only in test: test1
Only in test: test2
Only in test: test3
t:~/work# ls test
test1 test2 test3
t:~/work# ls test2/
test1 test2 test3

Associated revisions

Revision 2728f1bf
Added by Natanael Copa almost 4 years ago

main/busybox: fix for diff

fixes #381

Revision 27f84b41
Added by Natanael Copa almost 4 years ago

main/busybox: fix for diff

fixes #381
(cherry picked from commit 2728f1bf9db999a885ce77618b1d615646e4294f)

Revision 411e5b31
Added by Natanael Copa over 3 years ago

main/busybox: updated patch for diff

fixes #381

History

#2 Updated by Natanael Copa almost 4 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 100

#4 Updated by Ted Trask almost 4 years ago

  • Status changed from Resolved to Assigned
  • % Done changed from 100 to 50

I can confirm that the bug, as reported, is fixed in busybox-1.16.2-r1

However, the bug fix does not completely solve the problem. Trying "diff -r test test2//" will still result in the same problem. Removing a single '/' from the end does not get to the root cause of the problem, just masks the symptoms.

The problem does seem to only happen based upon '/' characters at the end of the directory, so maybe deleting any number of '/' characters? But, I still think there must be some other underlying reason. And any recursive diff comparing to the root '/' directory will still fail.

#5 Updated by Ted Trask almost 4 years ago

I noticed that busybox fixed the bug with different code than alpine did. Perhaps you could try http://git.busybox.net/busybox/commit/?id=61f5f7823c4f217dd9bad2f1df547f81b9338c76

#6 Updated by Natanael Copa over 3 years ago

  • Status changed from Assigned to Resolved
  • % Done changed from 50 to 100

#7 Updated by Natanael Copa over 3 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF