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

Unified Diff: net/http/http_response_headers.cc

Issue 188773005: Merge 255274 "Fixed chrome proxy via check" (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1847/src/
Patch Set: Created 6 years, 9 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/http/http_response_headers_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_response_headers.cc
===================================================================
--- net/http/http_response_headers.cc (revision 255461)
+++ net/http/http_response_headers.cc (working copy)
@@ -1431,7 +1431,8 @@
// space following it are always |kVersionSize| characters. E.g.,
// 'Via: 1.1 Chrome-Compression-Proxy'
while (EnumerateHeader(&iter, "via", &value)) {
- if (!value.compare(kVersionSize, value_len, kChromeProxyViaValue))
+ if (value.size() >= kVersionSize + value_len &&
+ !value.compare(kVersionSize, value_len, kChromeProxyViaValue))
return true;
}
« no previous file with comments | « no previous file | net/http/http_response_headers_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698