GNU bug report logs - #17367
od command not working correctly ?

Previous Next

Package: coreutils;

Reported by: "Dieter Walz" <dieter.walz <at> web.de>

Date: Tue, 29 Apr 2014 07:33:02 UTC

Severity: normal

Tags: notabug

Done: Pádraig Brady <P <at> draigBrady.com>

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 17367 in the body.
You can then email your comments to 17367 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-coreutils <at> gnu.org:
bug#17367; Package coreutils. (Tue, 29 Apr 2014 07:33:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Dieter Walz" <dieter.walz <at> web.de>:
New bug report received and forwarded. Copy sent to bug-coreutils <at> gnu.org. (Tue, 29 Apr 2014 07:33:03 GMT) Full text and rfc822 format available.

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

From: "Dieter Walz" <dieter.walz <at> web.de>
To: bug-coreutils <at> gnu.org
Subject: od command not working correctly ?
Date: Tue, 29 Apr 2014 08:20:52 +0200
[Message part 1 (text/html, inline)]

Information forwarded to bug-coreutils <at> gnu.org:
bug#17367; Package coreutils. (Tue, 29 Apr 2014 08:45:02 GMT) Full text and rfc822 format available.

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

From: Pádraig Brady <P <at> draigBrady.com>
To: Dieter Walz <dieter.walz <at> web.de>
Cc: 17367 <at> debbugs.gnu.org
Subject: Re: bug#17367: od command not working correctly ?
Date: Tue, 29 Apr 2014 09:44:43 +0100
tag 17367 notabug
close 17367
stop

On 04/29/2014 07:20 AM, Dieter Walz wrote:
>    Hi,
>    I've got a problem with od command; could anyone check, please?
> 
>    After editing and saving a file ...
>    [de139642 <at> oc0027726724 ~]$ cat temp.txt
>    a1
>    b2
>    c3
>    ... I wanted to browse it in hex mode by use of 'od' command, however I
>    failed
>    to obtain a correct image:
> 
>    [de139642 <at> oc0027726724 ~]$ od -t x temp.txt
>    0000000 620a3161 33630a32 00000a0a
>    0000012
>    [de139642 <at> oc0027726724 ~]$ od -t x2 temp.txt
>    0000000 3161 620a 0a32 3363 0a0a
>    0000012
>    [de139642 <at> oc0027726724 ~]$ od -x temp.txt
>    0000000 3161 620a 0a32 3363 0a0a
>    0000012
>    [de139642 <at> oc0027726724 ~]$
>    using vi (hex mode) instead, I got what I expected ....
>    1: 6131 0a62 320a 6333 0a0a                 a1.b2.c3..
>    Is there an error with od command or do I understand it badly?

I added EXAMPLES to the man page a while back,
which might be what you want:

  od -A x -t x1z -v
    Display hexdump format output

I notice the vi hex mode is using big endian 2 byte format.
If you do want that, you can get with the version of od in git like:

  $ od --endian=big -Ax -t x2z -v temp.txt
    000000 6131 0a62 320a 6333 0a00                 >a1.b2.c3.<

Pádraig.




Added tag(s) notabug. Request was from Pádraig Brady <P <at> draigBrady.com> to control <at> debbugs.gnu.org. (Tue, 29 Apr 2014 18:36:02 GMT) Full text and rfc822 format available.

bug closed, send any further explanations to 17367 <at> debbugs.gnu.org and "Dieter Walz" <dieter.walz <at> web.de> Request was from Pádraig Brady <P <at> draigBrady.com> to control <at> debbugs.gnu.org. (Tue, 29 Apr 2014 18:36:02 GMT) Full text and rfc822 format available.

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

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

Previous Next


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