Better handling of errors from CGI script.