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

Unified Diff: chrome/browser/chromeos/gdata/gdata_file_system.cc

Issue 10416049: gdata: Fix a bug that caused histograms on gdata files to be skewed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/gdata/gdata_file_system.cc
diff --git a/chrome/browser/chromeos/gdata/gdata_file_system.cc b/chrome/browser/chromeos/gdata/gdata_file_system.cc
index 33f5005ba54db05866dfcdf6aa8039b3d450830f..7855c7d011804e2bb3697c2df7dd572071408224 100644
--- a/chrome/browser/chromeos/gdata/gdata_file_system.cc
+++ b/chrome/browser/chromeos/gdata/gdata_file_system.cc
@@ -3648,11 +3648,14 @@ base::PlatformFileError GDataFileSystem::UpdateFromFeed(
if (should_notify_initial_load)
NotifyInitialLoadFinished();
- const int num_total_files = num_hosted_documents + num_regular_files;
- UMA_HISTOGRAM_COUNTS("GData.NumberOfRegularFiles", num_regular_files);
- UMA_HISTOGRAM_COUNTS("GData.NumberOfHostedDocuments",
- num_hosted_documents);
- UMA_HISTOGRAM_COUNTS("GData.NumberOfTotalFiles", num_total_files);
+ // Shouldn't record histograms when processing delta feeds.
+ if (!is_delta_feed) {
+ const int num_total_files = num_hosted_documents + num_regular_files;
+ UMA_HISTOGRAM_COUNTS("GData.NumberOfRegularFiles", num_regular_files);
+ UMA_HISTOGRAM_COUNTS("GData.NumberOfHostedDocuments",
+ num_hosted_documents);
+ UMA_HISTOGRAM_COUNTS("GData.NumberOfTotalFiles", num_total_files);
+ }
return base::PLATFORM_FILE_OK;
}
« 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