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

Unified Diff: net/tools/quic/test_tools/quic_test_client.cc

Issue 2399473003: StringPiece will be replaced with std::string_view. std::string_view doesn't have starts_with. (Closed)
Patch Set: Created 4 years, 2 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 | « net/tools/quic/quic_in_memory_cache.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/test_tools/quic_test_client.cc
diff --git a/net/tools/quic/test_tools/quic_test_client.cc b/net/tools/quic/test_tools/quic_test_client.cc
index 41846fd7d14d7c4cb611697c457829f999a3b216..e58916b0ee50e81677712e593fe8f8a2d0184a24 100644
--- a/net/tools/quic/test_tools/quic_test_client.cc
+++ b/net/tools/quic/test_tools/quic_test_client.cc
@@ -131,7 +131,9 @@ BalsaHeaders* MungeHeaders(const BalsaHeaders* const_headers) {
}
BalsaHeaders* headers = new BalsaHeaders;
headers->CopyFrom(*const_headers);
- if (!uri.starts_with("https://") && !uri.starts_with("http://")) {
+ if (!base::StartsWith(uri, "https://",
+ base::CompareCase::INSENSITIVE_ASCII) &&
+ !base::StartsWith(uri, "http://", base::CompareCase::INSENSITIVE_ASCII)) {
// If we have a relative URL, set some defaults.
string full_uri = "https://test.example.com";
full_uri.append(uri.as_string());
« no previous file with comments | « net/tools/quic/quic_in_memory_cache.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698