Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1937)

Unified Diff: net/server/http_server.cc

Issue 2648553002: HttpServer::ParseHeaders: don't DCHECK on bogus headers termination (Closed)
Patch Set: More refinements based on review feedback. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/server/http_server_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/server/http_server.cc
diff --git a/net/server/http_server.cc b/net/server/http_server.cc
index 7300a38f8c1b9704843728028044c4ed0f9b01fe..77c2c0d9b6c267a569e7344697a5a8c954deac92 100644
--- a/net/server/http_server.cc
+++ b/net/server/http_server.cc
@@ -449,8 +449,8 @@ bool HttpServer::ParseHeaders(const char* data,
buffer.append(&ch, 1);
break;
case ST_DONE:
- DCHECK(input == INPUT_LF);
- return true;
+ // We got CR to get this far, also need the LF
+ return (input == INPUT_LF);
case ST_ERR:
return false;
}
« no previous file with comments | « no previous file | net/server/http_server_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698