]> git.saurik.com Git - apt.git/commitdiff
* Fix pipeline handling on http.cc (closes: #413324)
authorOtavio Salvador <otavio@ossystems.com.br>
Tue, 10 Jul 2007 19:49:12 +0000 (16:49 -0300)
committerOtavio Salvador <otavio@ossystems.com.br>
Tue, 10 Jul 2007 19:49:12 +0000 (16:49 -0300)
debian/changelog
methods/http.cc

index 2699921964be5b84218ceab3979d82016edff8af..c81d487ab8e6ddfdc8ace91a833820280c73da28 100644 (file)
@@ -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
 
index 506e66faefe74c65e3fa251a2f3bfa653d17d753..068d26978186b06e35a1173775ddda2d6c3722d9 100644 (file)
@@ -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;
         }