add simple error handler for http parser.