in reply to Need help with SNMP script

Check your trap.cfg file for any blank lines and remove them.