| Index: net/filter/filter_source_stream.cc
|
| diff --git a/net/filter/filter_source_stream.cc b/net/filter/filter_source_stream.cc
|
| index 603bd703c8e7311744fc74e0ae868a383d0cb518..deb3af7f20b0b0653272a7d383a13431909698a3 100644
|
| --- a/net/filter/filter_source_stream.cc
|
| +++ b/net/filter/filter_source_stream.cc
|
| @@ -67,6 +67,11 @@ std::string FilterSourceStream::Description() const {
|
| return next_type_string + "," + GetTypeAsString();
|
| }
|
|
|
| +void FilterSourceStream::ReportContentDecodingFailed(SourceType type) {
|
| + UMA_HISTOGRAM_ENUMERATION("Net.ContentDecodingFailed2.FilterType", type,
|
| + TYPE_MAX);
|
| +}
|
| +
|
| int FilterSourceStream::DoLoop(int result) {
|
| DCHECK_NE(STATE_NONE, next_state_);
|
|
|
| @@ -135,10 +140,8 @@ int FilterSourceStream::DoFilterData() {
|
| DCHECK(bytes_output != 0 ||
|
| consumed_bytes == drainable_input_buffer_->BytesRemaining());
|
|
|
| - if (bytes_output == ERR_CONTENT_DECODING_FAILED) {
|
| - UMA_HISTOGRAM_ENUMERATION("Net.ContentDecodingFailed2.FilterType", type(),
|
| - TYPE_MAX);
|
| - }
|
| + if (bytes_output == ERR_CONTENT_DECODING_FAILED)
|
| + ReportContentDecodingFailed(type());
|
| // FilterData() is not allowed to return ERR_IO_PENDING.
|
| DCHECK_NE(ERR_IO_PENDING, bytes_output);
|
|
|
|
|