summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2007-07-10 16:49:12 -0300
committerOtavio Salvador <otavio@ossystems.com.br>2007-07-10 16:49:12 -0300
commit9a52beaad9a26454fe627dab3f87ebf08c799677 (patch)
tree081d861ec074d4e41f847272fc336c909b4a51e3
parent946392c230d5fbf31b7456576c0ee423e25bb58f (diff)
* Fix pipeline handling on http.cc (closes: #413324)
-rw-r--r--debian/changelog1
-rw-r--r--methods/http.cc19
2 files changed, 19 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index 269992196..c81d487ab 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -10,6 +10,7 @@ apt (0.7.4) UNRELEASED; urgency=low
- unused variable;
- changed SetupProxy() method to void;
* Simplified HttpMethod::Fetch on http.cc removing Tail variable;
+ * Fix pipeline handling on http.cc (closes: #413324)
-- Otavio Salvador <otavio@ossystems.com.br> Mon, 02 Jul 2007 13:27:54 -0300
diff --git a/methods/http.cc b/methods/http.cc
index 506e66fae..068d26978 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -1164,8 +1164,25 @@ int HttpMethod::Loop()
URIDone(Res);
}
else
- Fail(true);
+ {
+ if (Server->ServerFd == -1)
+ {
+ FailCounter++;
+ _error->Discard();
+ Server->Close();
+ if (FailCounter >= 2)
+ {
+ Fail(_("Connection failed"),true);
+ FailCounter = 0;
+ }
+
+ QueueBack = Queue;
+ }
+ else
+ Fail(true);
+ }
+
break;
}