[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#35209: Bug in zdiff argument of an option separated by a space is no
bug#35209: Bug in zdiff argument of an option separated by a space is not handled correctly
Tue, 9 Apr 2019 16:11:14 +0200
The zdiff script does not handle options with arguments separated by a
The following if a valid diff command: "diff -y -W 200 /tmp/b1 /tmp/b2".
But when passed to zdiff the space between "-W" and 200 causes the
COLUMNS argument to be interpreted as a file:
zdiff -y -W 200 /tmp/b1 /tmp/b2
/bin/zdiff: 72: /bin/zdiff: cannot open 200: No such file
The error is caused by the following line in the loop that processes
-?*) cmp="$cmp '$1'";; (line 63 in version 1.6)
There should be an additional check to catch options with arguments. I
couldn't come up with a working solution quickly so I am currently
using a workaround.
If I remove the space between the option "-W" and it's COLUMNS
argument the script works as expected.
With this workaround the zdiff utility is great solution for the
problem I'm working on, thanks!
Thanks in advance
|[Prev in Thread]
||[Next in Thread]|
- bug#35209: Bug in zdiff argument of an option separated by a space is not handled correctly,
Bram Mertens <=