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

Side by Side Diff: net/base/sdch_manager.cc

Issue 155064: Merge r18936.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/branches/172/src/
Patch Set: Created 11 years, 5 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 unified diff | Download patch
« no previous file with comments | « net/base/sdch_manager.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Modified: svn:mergeinfo
Merged /trunk/src/net/base/sdch_manager.cc:r14162,16808,17560,18936
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/field_trial.h" 5 #include "base/field_trial.h"
6 #include "base/histogram.h" 6 #include "base/histogram.h"
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/sha2.h" 8 #include "base/sha2.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "net/base/base64.h" 10 #include "net/base/base64.h"
(...skipping 14 matching lines...) Expand all
25 // static 25 // static
26 SdchManager* SdchManager::global_; 26 SdchManager* SdchManager::global_;
27 27
28 // static 28 // static
29 SdchManager* SdchManager::Global() { 29 SdchManager* SdchManager::Global() {
30 return global_; 30 return global_;
31 } 31 }
32 32
33 // static 33 // static
34 void SdchManager::SdchErrorRecovery(ProblemCodes problem) { 34 void SdchManager::SdchErrorRecovery(ProblemCodes problem) {
35 static LinearHistogram histogram("Sdch.ProblemCodes_3", MIN_PROBLEM_CODE, 35 static LinearHistogram histogram("Sdch3.ProblemCodes_4", MIN_PROBLEM_CODE,
36 MAX_PROBLEM_CODE - 1, MAX_PROBLEM_CODE); 36 MAX_PROBLEM_CODE - 1, MAX_PROBLEM_CODE);
37 histogram.SetFlags(kUmaTargetedHistogramFlag); 37 histogram.SetFlags(kUmaTargetedHistogramFlag);
38 histogram.Add(problem); 38 histogram.Add(problem);
39 } 39 }
40 40
41 // static 41 // static
42 void SdchManager::ClearBlacklistings() { 42 void SdchManager::ClearBlacklistings() {
43 Global()->blacklisted_domains_.clear(); 43 Global()->blacklisted_domains_.clear();
44 Global()->exponential_blacklist_count.clear(); 44 Global()->exponential_blacklist_count.clear();
45 } 45 }
(...skipping 461 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 return false; 507 return false;
508 return restriction[prefix_length - 1] == '/' || path[prefix_length] == '/'; 508 return restriction[prefix_length - 1] == '/' || path[prefix_length] == '/';
509 } 509 }
510 510
511 // static 511 // static
512 bool SdchManager::Dictionary::DomainMatch(const GURL& gurl, 512 bool SdchManager::Dictionary::DomainMatch(const GURL& gurl,
513 const std::string& restriction) { 513 const std::string& restriction) {
514 // TODO(jar): This is not precisely a domain match definition. 514 // TODO(jar): This is not precisely a domain match definition.
515 return gurl.DomainIs(restriction.data(), restriction.size()); 515 return gurl.DomainIs(restriction.data(), restriction.size());
516 } 516 }
OLDNEW
« no previous file with comments | « net/base/sdch_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698