judge the http code for response.