summaryrefslogtreecommitdiffstats
path: root/base/metrics
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-26 21:48:00 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-26 21:48:00 +0000
commita42d4638f0335dbfd14c1c9f6b05a7b09703a78e (patch)
tree96d7687e21b42cd5b5de4b23b2a1da472572e60c /base/metrics
parent1b5eee12138e3963415453974c824472429c4d80 (diff)
downloadchromium_src-a42d4638f0335dbfd14c1c9f6b05a7b09703a78e.zip
chromium_src-a42d4638f0335dbfd14c1c9f6b05a7b09703a78e.tar.gz
chromium_src-a42d4638f0335dbfd14c1c9f6b05a7b09703a78e.tar.bz2
Replace most LOG/CHECK statements with DLOG/DCHECK statements in base.
[ Reland of 107042 http://codereview.chromium.org/8368009 ] I tried hard not to change CHECKs that had side effects. I kept fatal checks that seemed security or debugging-info (in crash reports) sensitive, and ones that seems particularly well-conceived. Review URL: http://codereview.chromium.org/8341026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107434 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/metrics')
-rw-r--r--base/metrics/histogram.cc12
-rw-r--r--base/metrics/stats_table.cc2
2 files changed, 7 insertions, 7 deletions
diff --git a/base/metrics/histogram.cc b/base/metrics/histogram.cc
index 484d095..7077b09 100644
--- a/base/metrics/histogram.cc
+++ b/base/metrics/histogram.cc
@@ -268,7 +268,7 @@ bool Histogram::DeserializeHistogramInfo(const std::string& histogram_info) {
!pickle.ReadInt(&iter, &histogram_type) ||
!pickle.ReadInt(&iter, &pickle_flags) ||
!sample.Histogram::SampleSet::Deserialize(&iter, pickle)) {
- LOG(ERROR) << "Pickle error decoding Histogram: " << histogram_name;
+ DLOG(ERROR) << "Pickle error decoding Histogram: " << histogram_name;
return false;
}
DCHECK(pickle_flags & kIPCSerializationSourceFlag);
@@ -276,7 +276,7 @@ bool Histogram::DeserializeHistogramInfo(const std::string& histogram_info) {
// checks above and beyond those in Histogram::Initialize()
if (declared_max <= 0 || declared_min <= 0 || declared_max < declared_min ||
INT_MAX / sizeof(Count) <= bucket_count || bucket_count < 2) {
- LOG(ERROR) << "Values error decoding Histogram: " << histogram_name;
+ DLOG(ERROR) << "Values error decoding Histogram: " << histogram_name;
return false;
}
@@ -295,8 +295,8 @@ bool Histogram::DeserializeHistogramInfo(const std::string& histogram_info) {
} else if (histogram_type == BOOLEAN_HISTOGRAM) {
render_histogram = BooleanHistogram::FactoryGet(histogram_name, flags);
} else {
- LOG(ERROR) << "Error Deserializing Histogram Unknown histogram_type: "
- << histogram_type;
+ DLOG(ERROR) << "Error Deserializing Histogram Unknown histogram_type: "
+ << histogram_type;
return false;
}
@@ -433,7 +433,7 @@ Histogram::~Histogram() {
if (StatisticsRecorder::dump_on_exit()) {
std::string output;
WriteAscii(true, "\n", &output);
- LOG(INFO) << output;
+ DLOG(INFO) << output;
}
// Just to make sure most derived class did this properly...
@@ -1025,7 +1025,7 @@ StatisticsRecorder::~StatisticsRecorder() {
if (dump_on_exit_) {
std::string output;
WriteGraph("", &output);
- LOG(INFO) << output;
+ DLOG(INFO) << output;
}
// Clean up.
HistogramMap* histograms = NULL;
diff --git a/base/metrics/stats_table.cc b/base/metrics/stats_table.cc
index 3db008e..2bccc90 100644
--- a/base/metrics/stats_table.cc
+++ b/base/metrics/stats_table.cc
@@ -265,7 +265,7 @@ StatsTable::StatsTable(const std::string& name, int max_threads,
impl_ = Private::New(name, table_size, max_threads, max_counters);
if (!impl_)
- PLOG(ERROR) << "StatsTable did not initialize";
+ DPLOG(ERROR) << "StatsTable did not initialize";
}
StatsTable::~StatsTable() {