diff options
author | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-18 16:47:32 +0000 |
---|---|---|
committer | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-18 16:47:32 +0000 |
commit | d16659fd251cabdfdbf456ab8a8e8aafdab410b3 (patch) | |
tree | b9401af97751466c9ca85829c4362788af2b16b1 /net | |
parent | 369517f7c31667580be73190d153eaef73305263 (diff) | |
download | chromium_src-d16659fd251cabdfdbf456ab8a8e8aafdab410b3.zip chromium_src-d16659fd251cabdfdbf456ab8a8e8aafdab410b3.tar.gz chromium_src-d16659fd251cabdfdbf456ab8a8e8aafdab410b3.tar.bz2 |
Include C system headers before C++ system headers.
Document that GetHostAndPort returns an IPv6 literal
address with square brackets.
Document that the host parameter to the ProxyServer
constructor takes an IPv6 literal address with square
brackets.
R=eroman
BUG=N/A
TEST=N/A
Review URL: http://codereview.chromium.org/113494
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16287 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r-- | net/base/net_util.h | 7 | ||||
-rw-r--r-- | net/proxy/proxy_server.h | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/net/base/net_util.h b/net/base/net_util.h index 9aba789..9c59b90 100644 --- a/net/base/net_util.h +++ b/net/base/net_util.h @@ -7,12 +7,12 @@ #include "build/build_config.h" -#include <string> - #ifdef OS_WIN #include <windows.h> #endif +#include <string> + #include "base/basictypes.h" struct addrinfo; @@ -39,7 +39,8 @@ bool FileURLToFilePath(const GURL& url, FilePath* file_path); // Saves the result into |*host| and |*port|. If the input did not have // the optional port, sets |*port| to -1. // Returns true if the parsing was successful, false otherwise. -// The returned host is NOT canonicalized, and may be invalid. +// The returned host is NOT canonicalized, and may be invalid. If <host> is +// an IPv6 literal address, the returned host includes the square brackets. bool GetHostAndPort(std::string::const_iterator host_and_port_begin, std::string::const_iterator host_and_port_end, std::string* host, diff --git a/net/proxy/proxy_server.h b/net/proxy/proxy_server.h index a3d5ca8..9060c39 100644 --- a/net/proxy/proxy_server.h +++ b/net/proxy/proxy_server.h @@ -29,6 +29,8 @@ class ProxyServer { // Constructs an invalid ProxyServer. ProxyServer() : scheme_(SCHEME_INVALID), port_(-1) {} + // If |host| is an IPv6 literal address, it must include the square + // brackets. ProxyServer(Scheme scheme, const std::string& host, int port) : scheme_(scheme), host_(host), port_(port) {} |