Date: Mon, 27 Nov 2000 12:59:57 +0000 From: Steve Roome <steve@sse0691.bri.hp.com> To: Rich Morin <rdm@cfcl.com> Cc: freebsd-doc@FreeBSD.ORG Subject: Re: od Message-ID: <20001127125957.A47315@moose.bri.hp.com> In-Reply-To: <p05001918b646efe10a3c@[192.168.168.205]>; from rdm@cfcl.com on Sun, Nov 26, 2000 at 08:52:58AM -0800 References: <20001126150107.A68587@uk.clara.net> <20001126160836.A6889@canyon.nothing-going-on.org> <20001126163319.A68842@uk.clara.net> <p05001918b646efe10a3c@[192.168.168.205]>
next in thread | previous in thread | raw e-mail | index | archive | help
> od [-aBbcDdeFfHhIiLlOovXx] [[+]offset[.][Bb]] file This may help : Okay, I pulled this out of the HP-UX 10.20 distribution, which was in the section titled : DESCRIPTION OF PRE-POSIX USAGE -b Interpret bytes in octal (hexadecimal). -c Interpret bytes in ASCII. Certain non-graphic characters appear as C escapes: null=\0, backspace=\b, form-feed=\f, new-line=\n, return=\r, tab=\t; others appear as 3-digit octal numbers. -d Interpret 16-bit words in decimal. -o Interpret 16-bit words in octal. -s Interpret 16-bit words in signed decimal. -x Interpret 16-bit words in hexadecimal. I guess that's why we don't have much info on it, hexdump would seem to do all this as well. Anyway, the above still seems accurate. I think the following is also true, but I'm not sure. -D Interpret 32-bit words in decimal hpux says that offset is as follows : offset specifies the offset in the file where dumping is to commence, and is normally interpreted as octal bytes. Interpretation can be altered as follows: + offset must be preceded by + if the file argument is omitted. + offset preceded by 0x is interpreted in hexadecimal. + offset followed by . is interpreted in decimal. + offset followed by b is interpreted in blocks of 512 bytes. Dumping continues until end-of-file. I doubt very much that the hpux version has changed significantly from wherever it was taken from, and I doubt ours has either.. I can get you the full manpage for od if you like. It seems fairly accurate to our version (not found anything wrong yet). This is so far, the first time I've used an hpux manpage to understand a FreeBSD command, usually I do this the other way round! =) Steve > > DESCRIPTION > Od has been deprecated in favor of hexdump(1). > > Hexdump, if called as od, provides compatibility for the options listed > above. > > It does not provide compatibility for the -s option (see strings(1)) or > the -P, -p, or -w options, nor is compatibility provided for the ``la- > bel'' component of the offset syntax. > > SEE ALSO > hexdump(1), strings(1) > > BUGS > Quite a few. > > HISTORY > A od command appeared in Version 1 AT&T UNIX. > > BSD May 27, 1994 1 > -- > -- > Rich Morin: rdm@cfcl.com, +1 650-873-7841, http://www.cfcl.com/rdm > Prime Time Freeware: info@ptf.com, +1 408-433-9662, http://www.ptf.com > MacPerl: http://www.macperl.com, http://www.ptf.com/ptf/products/MPPE > MkLinux: http://www.mklinux.org, http://www.ptf.com/ptf/products/MKLP > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-doc" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001127125957.A47315>