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

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

Issue 1294713004: Switch Sdch3.AdvertisedWithSecureScheme histogram to use target_url.SchemeIsCryptographic(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "net/base/sdch_manager.h" 5 #include "net/base/sdch_manager.h"
6 6
7 #include "base/base64.h" 7 #include "base/base64.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/histogram_macros.h" 9 #include "base/metrics/histogram_macros.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 continue; 251 continue;
252 ++count; 252 ++count;
253 result->AddDictionary(entry.first, entry.second); 253 result->AddDictionary(entry.first, entry.second);
254 } 254 }
255 255
256 if (count == 0) 256 if (count == 0)
257 return NULL; 257 return NULL;
258 258
259 UMA_HISTOGRAM_COUNTS("Sdch3.Advertisement_Count", count); 259 UMA_HISTOGRAM_COUNTS("Sdch3.Advertisement_Count", count);
260 UMA_HISTOGRAM_BOOLEAN("Sdch3.AdvertisedWithSecureScheme", 260 UMA_HISTOGRAM_BOOLEAN("Sdch3.AdvertisedWithSecureScheme",
261 target_url.SchemeIsSecure()); 261 target_url.SchemeIsCryptographic());
262 262
263 return result.Pass(); 263 return result.Pass();
264 } 264 }
265 265
266 scoped_ptr<SdchManager::DictionarySet> 266 scoped_ptr<SdchManager::DictionarySet>
267 SdchManager::GetDictionarySetByHash( 267 SdchManager::GetDictionarySetByHash(
268 const GURL& target_url, 268 const GURL& target_url,
269 const std::string& server_hash, 269 const std::string& server_hash,
270 SdchProblemCode* problem_code) { 270 SdchProblemCode* problem_code) {
271 scoped_ptr<SdchManager::DictionarySet> result; 271 scoped_ptr<SdchManager::DictionarySet> result;
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 entry_dict->SetInteger("tries", it->second.count); 488 entry_dict->SetInteger("tries", it->second.count);
489 entry_dict->SetInteger("reason", it->second.reason); 489 entry_dict->SetInteger("reason", it->second.reason);
490 entry_list->Append(entry_dict.Pass()); 490 entry_list->Append(entry_dict.Pass());
491 } 491 }
492 value->Set("blacklisted", entry_list.Pass()); 492 value->Set("blacklisted", entry_list.Pass());
493 493
494 return value.Pass(); 494 return value.Pass();
495 } 495 }
496 496
497 } // namespace net 497 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698