in reply to nonprinting chars

Don't forget this little ditty (IF killing unprintables is what you're after and your Perl is new enough--the \r advice above is great already):

perl -pi.bk -e 's/[^[:print:]]//g'