summaryrefslogtreecommitdiff
path: root/methods/http.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2019-07-08 15:48:59 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2019-07-08 15:51:17 +0200
commit2b734a7ec429825c7007c1093883229e069d36c7 (patch)
treeb67360f3201634c82f5a9e7dd84f47b28fa63acb /methods/http.cc
parentcbe90ee516d7f747f981e423f164f99eb767240b (diff)
Apply various suggestions by cppcheck
Reported-By: cppcheck
Diffstat (limited to 'methods/http.cc')
-rw-r--r--methods/http.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/methods/http.cc b/methods/http.cc
index a4d187189..0a29109fb 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -349,7 +349,7 @@ static ResultState UnwrapHTTPConnect(std::string Host, int Port, URI Proxy, std:
Out.Read(Req.str());
// Writing from proxy
- while (Out.WriteSpace() > 0)
+ while (Out.WriteSpace())
{
if (WaitFd(Fd->Fd(), true, Timeout) == false)
{
@@ -363,7 +363,7 @@ static ResultState UnwrapHTTPConnect(std::string Host, int Port, URI Proxy, std:
}
}
- while (In.ReadSpace() > 0)
+ while (In.ReadSpace())
{
if (WaitFd(Fd->Fd(), false, Timeout) == false)
{
@@ -389,7 +389,7 @@ static ResultState UnwrapHTTPConnect(std::string Host, int Port, URI Proxy, std:
return ResultState::TRANSIENT_ERROR;
}
- if (In.WriteSpace() > 0)
+ if (In.WriteSpace())
{
// Maybe there is actual data already read, if so we need to buffer it
std::unique_ptr<HttpConnectFd> NewFd(new HttpConnectFd());