From c3643277b20fbb232569566a90babe2dae2ec730 Mon Sep 17 00:00:00 2001 From: Chunting Gu Date: Mon, 21 Dec 2020 20:14:46 +0800 Subject: [PATCH] Update request_parser.cc handle empty form part --- webcc/request_parser.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webcc/request_parser.cc b/webcc/request_parser.cc index a626ef3..3148a29 100644 --- a/webcc/request_parser.cc +++ b/webcc/request_parser.cc @@ -120,7 +120,7 @@ bool RequestParser::ParseMultipartContent(const char* data, // Next boundary found. // This part has ended. - if (off > 2) { + if (off >= 2) { // -2 for excluding the CRLF after the data. part_->AppendData(pending_data_.data(), off - 2);