Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(80)

Unified Diff: net/base/host_mapping_rules.cc

Issue 647883002: git cl format the final third of the net/base directory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/base/host_mapping_rules.cc
diff --git a/net/base/host_mapping_rules.cc b/net/base/host_mapping_rules.cc
index f91f3fd0b4e7e2547123d50b72fe6ecbe5ce079a..feb5c52efa31b432e5d20c42880c2c09f73accb9 100644
--- a/net/base/host_mapping_rules.cc
+++ b/net/base/host_mapping_rules.cc
@@ -25,14 +25,17 @@ struct HostMappingRules::ExclusionRule {
std::string hostname_pattern;
};
-HostMappingRules::HostMappingRules() {}
+HostMappingRules::HostMappingRules() {
+}
-HostMappingRules::~HostMappingRules() {}
+HostMappingRules::~HostMappingRules() {
+}
bool HostMappingRules::RewriteHost(HostPortPair* host_port) const {
// Check if the hostname was excluded.
for (ExclusionRuleList::const_iterator it = exclusion_rules_.begin();
- it != exclusion_rules_.end(); ++it) {
+ it != exclusion_rules_.end();
+ ++it) {
const ExclusionRule& rule = *it;
if (MatchPattern(host_port->host(), rule.hostname_pattern))
return false;
@@ -40,7 +43,8 @@ bool HostMappingRules::RewriteHost(HostPortPair* host_port) const {
// Check if the hostname was remapped.
for (MapRuleList::const_iterator it = map_rules_.begin();
- it != map_rules_.end(); ++it) {
+ it != map_rules_.end();
mef 2014/10/10 20:38:17 3 lines in for.
+ ++it) {
const MapRule& rule = *it;
// The rule's hostname_pattern will be something like:
@@ -84,8 +88,8 @@ bool HostMappingRules::AddRuleFromString(const std::string& rule_string) {
MapRule rule;
rule.hostname_pattern = base::StringToLowerASCII(parts[1]);
- if (!ParseHostAndPort(parts[2], &rule.replacement_hostname,
- &rule.replacement_port)) {
+ if (!ParseHostAndPort(
+ parts[2], &rule.replacement_hostname, &rule.replacement_port)) {
return false; // Failed parsing the hostname/port.
}

Powered by Google App Engine
This is Rietveld 408576698