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

Unified Diff: url/url_util.h

Issue 2562813003: Merge logic for SameDomainOrHost for GURLs and Origins (Closed)
Patch Set: Created 4 years 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
Index: url/url_util.h
diff --git a/url/url_util.h b/url/url_util.h
index 724ce956a7ffa95010218717db15342f0d0d4dd5..e272e436d0824249ffaf02b9dd0d4ac4e350adb3 100644
--- a/url/url_util.h
+++ b/url/url_util.h
@@ -146,6 +146,12 @@ URL_EXPORT bool GetStandardSchemeType(const char* spec,
URL_EXPORT bool DomainIs(base::StringPiece canonicalized_host,
base::StringPiece lower_ascii_domain);
+// Hosts -----------------------------------------------------------------------
+
+// Returns true if the hostname is an IP address. Note: this function isn't very
+// cheap, as it must re-parse the host to verify.
+URL_EXPORT bool HostIsIPAddress(base::StringPiece host);
+
// URL library wrappers --------------------------------------------------------
// Parses the given spec according to the extracted scheme type. Normal users

Powered by Google App Engine
This is Rietveld 408576698