]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Fix regression in mime header boundary detection
authorAmos Jeffries <squid3@treenet.co.nz>
Mon, 2 Jun 2014 15:11:59 +0000 (08:11 -0700)
committerAmos Jeffries <squid3@treenet.co.nz>
Mon, 2 Jun 2014 15:11:59 +0000 (08:11 -0700)
src/http/one/RequestParser.cc

index 9e8ba8aa59870d5d3732f63a88215e7b9f9164ed..87bbfdcc8111a5aff00b41015a6a70781b3f6ad2 100644 (file)
@@ -344,8 +344,8 @@ Http::One::RequestParser::parse(const SBuf &aBuf)
                     debugs(33, 5, "Incomplete request, waiting for end of headers");
                 return false;
             }
-            mimeHeaderBlock_ = buf_.substr(req.end+1, mimeHeaderBytes);
-            buf_.consume(mimeHeaderBytes); // done with these bytes now.
+            mimeHeaderBlock_ = buf_.consume(mimeHeaderBytes);
+            debugs(74, 5, "mime header (0-" << mimeHeaderBytes << ") {" << mimeHeaderBlock_ << "}");
 
         } else
             debugs(33, 3, "Missing HTTP/1.x identifier");