Improved error reporting

New function errcho() used to report an error and exit.