Index: net/base/net_util.h |
diff --git a/net/base/net_util.h b/net/base/net_util.h |
index ad5795cdb3df8edcc9c3bd59dfd841f8ad81ddeb..bb145e0df0a3b6b7e85b402b2cfb3ea22e245755 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,17 @@ GURL SimplifyUrlForRequest(const GURL& url); |
void SetExplicitlyAllowedPorts(const std::string& allowed_ports); |
+class ScopedPortException { |
+ public: |
+ ScopedPortException(int port); |
+ ~ScopedPortException(); |
+ |
+ private: |
+ int port_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(ScopedPortException); |
+}; |
+ |
// 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. |