don't let bad http request kill bot, also fix for connection close