summaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authoravi <avi@chromium.org>2015-12-01 11:27:07 -0800
committerCommit bot <commit-bot@chromium.org>2015-12-01 19:35:33 +0000
commit6516805e8c69ac65bcb7d52a2a208be97a7d2a50 (patch)
tree0d67ff4a6fa2fe00b7dc5c51895b162599bab1f3 /components
parente5bfeba55d3d80aa4f5c8385ede94853789b0a9a (diff)
downloadchromium_src-6516805e8c69ac65bcb7d52a2a208be97a7d2a50.zip
chromium_src-6516805e8c69ac65bcb7d52a2a208be97a7d2a50.tar.gz
chromium_src-6516805e8c69ac65bcb7d52a2a208be97a7d2a50.tar.bz2
Remove kuint16max.
BUG=138542 Committed: https://crrev.com/0d94fda8c494d7a6c27d065d782f42e99d834f46 Cr-Commit-Position: refs/heads/master@{#362431} Review URL: https://codereview.chromium.org/1475803002 Cr-Commit-Position: refs/heads/master@{#362472}
Diffstat (limited to 'components')
-rw-r--r--components/policy/core/browser/url_blacklist_manager.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/components/policy/core/browser/url_blacklist_manager.cc b/components/policy/core/browser/url_blacklist_manager.cc
index 5d85138..4b4d35e 100644
--- a/components/policy/core/browser/url_blacklist_manager.cc
+++ b/components/policy/core/browser/url_blacklist_manager.cc
@@ -4,6 +4,10 @@
#include "components/policy/core/browser/url_blacklist_manager.h"
+#include <stdint.h>
+
+#include <limits>
+
#include "base/bind.h"
#include "base/files/file_path.h"
#include "base/location.h"
@@ -137,7 +141,7 @@ struct URLBlacklist::FilterComponents {
std::string scheme;
std::string host;
- uint16 port;
+ uint16_t port;
std::string path;
std::string query;
int number_of_key_value_pairs;
@@ -235,7 +239,7 @@ bool URLBlacklist::FilterToComponents(SegmentURLCallback segment_url,
std::string* scheme,
std::string* host,
bool* match_subdomains,
- uint16* port,
+ uint16_t* port,
std::string* path,
std::string* query) {
url::Parsed parsed;
@@ -298,7 +302,7 @@ bool URLBlacklist::FilterToComponents(SegmentURLCallback segment_url,
&int_port)) {
return false;
}
- if (int_port <= 0 || int_port > kuint16max)
+ if (int_port <= 0 || int_port > std::numeric_limits<uint16_t>::max())
return false;
*port = int_port;
} else {
@@ -328,7 +332,7 @@ scoped_refptr<URLMatcherConditionSet> URLBlacklist::CreateConditionSet(
const std::string& scheme,
const std::string& host,
bool match_subdomains,
- uint16 port,
+ uint16_t port,
const std::string& path,
const std::string& query,
bool allow) {