[prog] is this a bug with `od` ??
Hamster
hamster at hamsternet.org
Mon Nov 10 21:22:11 EST 2003
Hi,
I've been playing round with `od` all day today, and came across a behaviour
which I'm not sure is intentional, or if the problem lies with me.
Let's say I use od to view the contents of a file using the following set of
parameters: `od -A x -tx1 file`
I'll get the following output:
$ od -A x -tx1 file
000000 20 30 38 0a
000004
$
However, if I try to switch off the printing of the offset, using `od -A n`,
then the output I get is as follows:
$ od -A n -tx1 file
20 30 38 0a
$
What I'm harping on about here is that it puts a space before the output
when you switch off printing of the offset.
To me, it looks like a bug; the code omits the offset, but doesnt omit the
space between the offset and the start of the file contents.
What do other people think? Is that space there for a reason?
Hamster
More information about the Programming
mailing list