ok, i've got a question...

Larry Wall lwall at jpl-devvax.JPL.NASA.GOV
Wed Sep 26 04:59:26 AEST 1990


In article <42900 at sequent.UUCP> calvin at sequent.UUCP (Calvin Goodrich) writes:
: ...for the unix.gods out there. i have a file that has a whole mess of
: null characters in it ('bout 1/2 a meg). is there any way (preferably
: a shell script) to strip them off?

If your tr works like mine, you can just say

	tr '' '' <foo >bar

Other possibilities:

	sed '' <foo >bar
	perl -pe 's/\0//g' <foo >bar

Larry Wall
lwall at jpl-devvax.jpl.nasa.gov



More information about the Comp.unix.shell mailing list