Skip to content

Commit

Permalink
fix DumpHeaders duplicated cookies (#599)
Browse files Browse the repository at this point in the history
Co-authored-by: llx <llx@U-Q6Q0149D-2359.local>
  • Loading branch information
caijillx and llx authored Aug 1, 2024
1 parent 6dd31fc commit 0b8149c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions http/Http1Parser.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ class Http1Parser : public HttpParser {
HttpCookie cookie;
if (cookie.parse(header_value)) {
parsed->cookies.emplace_back(cookie);
header_field.clear();
header_value.clear();
return;
}
}
parsed->headers[header_field] = header_value;
Expand Down

0 comments on commit 0b8149c

Please sign in to comment.