Chromium Code Reviews| Index: net/base/net_util.h |
| diff --git a/net/base/net_util.h b/net/base/net_util.h |
| index ad5795cdb3df8edcc9c3bd59dfd841f8ad81ddeb..9a2169a22328f89fc0c219ac3355b541c02ff033 100644 |
| --- a/net/base/net_util.h |
| +++ b/net/base/net_util.h |
| @@ -71,7 +71,7 @@ extern const FormatUrlType kFormatUrlOmitTrailingSlashOnBareHostname; |
| extern const FormatUrlType kFormatUrlOmitAll; |
| // Holds a list of ports that should be accepted despite bans. |
| -extern std::set<int> explicitly_allowed_ports; |
| +extern std::multiset<int> explicitly_allowed_ports; |
| // Given the full path to a file name, creates a file: URL. The returned URL |
| // may not be valid if the input is malformed. |
| @@ -338,6 +338,15 @@ GURL SimplifyUrlForRequest(const GURL& url); |
| void SetExplicitlyAllowedPorts(const std::string& allowed_ports); |
| +class ScopedPortException { |
|
cbentzel
2010/12/09 14:25:13
DISALLOW_COPY_AND_ASSIGN
|
| + public: |
| + ScopedPortException(int port); |
| + ~ScopedPortException(); |
| + |
| + private: |
| + int port_; |
| +}; |
| + |
| // Perform a simplistic test to see if IPv6 is supported by trying to create an |
| // IPv6 socket. |
| // TODO(jar): Make test more in-depth as needed. |