Improved error handling for http logging in.