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

Unified Diff: third_party/WebKit/Source/platform/network/HTTPParsers.cpp

Issue 2227903002: String::contains should use StringView. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 | third_party/WebKit/Source/wtf/text/AtomicString.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/network/HTTPParsers.cpp
diff --git a/third_party/WebKit/Source/platform/network/HTTPParsers.cpp b/third_party/WebKit/Source/platform/network/HTTPParsers.cpp
index 593f095228b8991210d9d69e33263f33a1de6f08..8dbe206e855b49390f16350b4bc42f360783ef3c 100644
--- a/third_party/WebKit/Source/platform/network/HTTPParsers.cpp
+++ b/third_party/WebKit/Source/platform/network/HTTPParsers.cpp
@@ -186,7 +186,10 @@ bool isValidHTTPHeaderValue(const String& name)
// FIXME: This should really match name against
// field-value in section 4.2 of RFC 2616.
- return name.containsOnlyLatin1() && !name.contains('\r') && !name.contains('\n') && !name.contains(static_cast<UChar>('\0'));
esprehn 2016/08/09 04:39:04 There's no reason to upcast to UChar here, we just
+ return name.containsOnlyLatin1()
+ && !name.contains('\r')
+ && !name.contains('\n')
+ && !name.contains('\0');
}
// See RFC 7230, Section 3.2.
« no previous file with comments | « no previous file | third_party/WebKit/Source/wtf/text/AtomicString.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698