summaryrefslogtreecommitdiffstats
path: root/net/base/net_util.cc
diff options
context:
space:
mode:
authorericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-08 18:40:05 +0000
committerericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-08 18:40:05 +0000
commit72569645fdd3ab18b27466e5d32149b2d2ed1172 (patch)
tree7d68a44f5e8dff7d30b73f9a6ecea3668c94f9f1 /net/base/net_util.cc
parentddf9d4aea57b36326ace447318cc06beb21ff9d2 (diff)
downloadchromium_src-72569645fdd3ab18b27466e5d32149b2d2ed1172.zip
chromium_src-72569645fdd3ab18b27466e5d32149b2d2ed1172.tar.gz
chromium_src-72569645fdd3ab18b27466e5d32149b2d2ed1172.tar.bz2
Pull in new googleurl@94 which includes GURL::EffectiveIntPort().
Update callers to use this method. Review URL: http://codereview.chromium.org/5641 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3024 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/net_util.cc')
-rw-r--r--net/base/net_util.cc22
1 files changed, 0 insertions, 22 deletions
diff --git a/net/base/net_util.cc b/net/base/net_util.cc
index 57448af..305cbcc 100644
--- a/net/base/net_util.cc
+++ b/net/base/net_util.cc
@@ -913,26 +913,4 @@ bool IsPortAllowedByFtp(int port) {
return IsPortAllowedByDefault(port);
}
-std::string GetImplicitPort(const GURL& url) {
- if (url.has_port())
- return url.port();
-
- // TODO(eroman): unify with DefaultPortForScheme()
- // [url_canon_stdurl.cc]
-
- static const struct {
- const char* scheme;
- const char* port;
- } scheme_map[] = {
- { "http", "80" },
- { "https", "443" },
- { "ftp", "21" }
- };
- for (int i = 0; i < static_cast<int>(ARRAYSIZE_UNSAFE(scheme_map)); ++i) {
- if (url.SchemeIs(scheme_map[i].scheme))
- return scheme_map[i].port;
- }
- return std::string("");
-}
-
} // namespace net