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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_blocking_page.cc

Issue 462027: Use factory to create histograms, and refcounts to track lifetimes... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years 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
« no previous file with comments | « chrome/browser/renderer_host/buffered_resource_handler.cc ('k') | chrome/browser/ssl/ssl_blocking_page.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/safe_browsing/safe_browsing_blocking_page.cc
===================================================================
--- chrome/browser/safe_browsing/safe_browsing_blocking_page.cc (revision 33932)
+++ chrome/browser/safe_browsing/safe_browsing_blocking_page.cc (working copy)
@@ -69,9 +69,11 @@
};
void RecordSafeBrowsingBlockingPageStats(SafeBrowsingBlockingPageEvent event) {
- static LinearHistogram histogram("interstial.safe_browsing", 0, 2, 3);
- histogram.SetFlags(kUmaTargetedHistogramFlag);
- histogram.Add(event);
+ static scoped_refptr<Histogram> histogram =
+ LinearHistogram::LinearHistogramFactoryGet("interstial.safe_browsing",
+ 1, 2, 3);
+ histogram->SetFlags(kUmaTargetedHistogramFlag);
+ histogram->Add(event);
}
} // namespace
« no previous file with comments | « chrome/browser/renderer_host/buffered_resource_handler.cc ('k') | chrome/browser/ssl/ssl_blocking_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698