From: David Kalnischkies Date: Sat, 25 Jun 2016 10:32:11 +0000 (+0200) Subject: close server if parsing of header field failed X-Git-Tag: 1.2.15~52 X-Git-Url: https://git.saurik.com/apt.git/commitdiff_plain/0216269ff9090e773ae2a0616e5aaecf0a13af8b?ds=inline close server if parsing of header field failed Seen in #828011 if we fail to parse a header field like Last-Modified we end up interpreting the data as response header for coming requests in case we don't rotate to a new server in DNS rotation. (cherry picked from commit cc0a4c82b3c132abba9b9ec35fd61bc8b45a1b80) --- diff --git a/methods/server.cc b/methods/server.cc index a46b40936..63c7486dd 100644 --- a/methods/server.cc +++ b/methods/server.cc @@ -527,6 +527,7 @@ int ServerMethod::Loop() { _error->Error(_("Bad header data")); Fail(true); + Server->Close(); RotateDNS(); continue; }