check_http: timeout problem on http redirection case [sf#2200323]

Just turning attached patch of github issue #826 into a push request