summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/base/net_util.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/base/net_util.cc b/net/base/net_util.cc
index 8ab1367..1aaa98b 100644
--- a/net/base/net_util.cc
+++ b/net/base/net_util.cc
@@ -1373,8 +1373,7 @@ std::string GetDirectoryListingEntry(const string16& name,
string16 StripWWW(const string16& text) {
const string16 www(ASCIIToUTF16("www."));
- return (text.compare(0, www.length(), www) == 0) ?
- text.substr(www.length()) : text;
+ return StartsWith(text, www, true) ? text.substr(www.length()) : text;
}
string16 GetSuggestedFilename(const GURL& url,