busybox 1.2.1 diff is buggy

Dirk Clemens develop at cle-mens.de
Sat Jan 6 06:19:50 PST 2007


Hi

I use busybox 1.2.1 with current patches on
a Siemens Gigaset M740AV (dvb-t setopbox, mips)

I have found the following diff error:

$ echo abc >foo
$ echo abc | diff - foo
--- -   Sat Jan  6 15:12:21 2007
+++ foo Sat Jan  6 15:12:12 2007
@@ -0,0 +1 @@
+abc

$ echo $?
1

$echo xyz | diff - foo
--- -   Sat Jan  6 15:12:35 2007
+++ foo Sat Jan  6 15:12:12 2007
@@ -0,0 +1 @@
+abc

$ echo $?
1

and my last test ...
$ diff - foo
reads from stdin


And that means:
diff is reading from stdin, but thinking, that stdin is empty.


Dirk


More information about the busybox mailing list