The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Sed command with characters IHulky UNIX for Dummies Questions & Answers 7 04-26-2007 03:14 AM
Command to get only the Three Characters of the Month prashanth_gs UNIX for Dummies Questions & Answers 2 02-12-2007 04:38 AM
Finding absolute pathnames longer than 100 characters nauty UNIX for Dummies Questions & Answers 2 05-12-2006 08:53 AM
Finding printers from a command prompt gseyforth Windows & DOS: Issues & Discussions 1 03-28-2006 05:24 AM
finding exact characters jrdnoland1 UNIX for Dummies Questions & Answers 3 03-25-2002 07:52 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 04-30-2005
Registered User
 

Join Date: Oct 2003
Location: Rio de Janeiro - Brazil
Posts: 37
Unix Command for finding Nul Characters

Hi Folks,


I have this windowed applescript application I use for sending out emails, it uses the Postfix daemon buit into my Mac Os X box, and a 3 SMTP servers (out of hundreds I send emails to) were refusing my messages replying "host smtp2.braspress.com.br[200.187.158.140] said: 550 Requested action not taken: NUL characters are not allowed. (in reply to end of DATA command)"

As a novice high-level programmer, I did not know that every character is represented by a hex value, and that I had two "gremlins" in my Template text (used to send out the emails after text manipulation), I mean, I had two hex values = 00.

A experienced Objective C programmer, friend of mine, taught me the what these Nul characters are and helped me removing these from my text. I was using a text application that did not show me the little gremlins.

As I move on forward with my learning, I am wondering if there is a Unix command I can use to detect these Gremlins, and so create a routine in my application to check the consistency of any text I use for sending out emails.

I thank you for your comments,

Bernardo Höhl
Rio de Janeiro - Brazil
Reply With Quote
Forum Sponsor
  #2  
Old 05-01-2005
kduffin's Avatar
UN1X
 

Join Date: Nov 2003
Location: Virginia
Posts: 441
Bernardo,

Você é afortunado estar em Bazil bonito! I need to find a way down there.

You can use "octal dump" to view/parse for any such characters. Look at the output of "od -c" against the file and read the man page for "od".

Cheers,

Keith
Reply With Quote
  #3  
Old 05-01-2005
Registered User
 

Join Date: Oct 2003
Location: Rio de Janeiro - Brazil
Posts: 37
Hi kduffin,


Thanks for the help!

My man page for od says:

odhas been deprecated in favor of hexdump(1).

Hexdump,if called as ,provides compatibility for the options listed above.

I guess hexdump is about the same thing. Isn't it?

I apparently get the same results as is od...

I have learned a lot today.

Thank you!


Bernardo
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 10:11 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0