summaryrefslogtreecommitdiff
path: root/methods
diff options
context:
space:
mode:
Diffstat (limited to 'methods')
-rw-r--r--methods/basehttp.cc33
1 files changed, 13 insertions, 20 deletions
diff --git a/methods/basehttp.cc b/methods/basehttp.cc
index 5e29e0ce1..b8ab73155 100644
--- a/methods/basehttp.cc
+++ b/methods/basehttp.cc
@@ -770,31 +770,24 @@ int BaseHttpMethod::Loop()
}
else
{
- if (Server->IsOpen() == false && FailCounter < 1)
+ if (not Server->IsOpen())
{
- FailCounter++;
- Server->Close();
- _error->Discard();
-
// Reset the pipeline
QueueBack = Queue;
Server->PipelineAnswersReceived = 0;
- continue;
}
- else
- {
- Server->Close();
- FailCounter = 0;
- switch (Result)
- {
- case ResultState::TRANSIENT_ERROR:
- Fail(true);
- break;
- case ResultState::FATAL_ERROR:
- case ResultState::SUCCESSFUL:
- Fail(false);
- break;
- }
+
+ Server->Close();
+ FailCounter = 0;
+ switch (Result)
+ {
+ case ResultState::TRANSIENT_ERROR:
+ Fail(true);
+ break;
+ case ResultState::FATAL_ERROR:
+ case ResultState::SUCCESSFUL:
+ Fail(false);
+ break;
}
}
break;