summaryrefslogtreecommitdiff
path: root/methods
diff options
context:
space:
mode:
Diffstat (limited to 'methods')
-rw-r--r--methods/http.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/methods/http.cc b/methods/http.cc
index 76d4f6b5a..fef719e74 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -711,6 +711,8 @@ ResultState HttpServerState::Die(RequestState &Req)
// can't be set
if (Req.File.Name() != "/dev/null")
SetNonBlock(Req.File.Fd(),false);
+ if (not In.WriteSpace())
+ return ResultState::SUCCESSFUL;
while (In.WriteSpace() == true)
{
if (In.Write(MethodFd::FromFd(Req.File.Fd())) == false)
@@ -723,6 +725,9 @@ ResultState HttpServerState::Die(RequestState &Req)
if (In.IsLimit() == true)
return ResultState::SUCCESSFUL;
}
+
+ if (In.IsLimit() == true || Persistent == false)
+ return ResultState::SUCCESSFUL;
}
// See if this is because the server finished the data stream