Fixed proxy status code check
This commit is contained in:
parent
599775c83f
commit
fa4dd130e5
1 changed files with 1 additions and 1 deletions
|
|
@ -96,7 +96,7 @@ namespace SimpleWeb {
|
|||
io_service.run();
|
||||
|
||||
auto response=request_read();
|
||||
if (response->status_code.size()>0 && response->status_code.substr(0,3) != "200") {
|
||||
if (response->status_code.empty() || response->status_code.substr(0,3) != "200") {
|
||||
std::lock_guard<std::mutex> lock(socket_mutex);
|
||||
socket=nullptr;
|
||||
throw boost::system::system_error(boost::system::error_code(boost::system::errc::permission_denied, boost::system::generic_category()));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue