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

Unified Diff: net/filter/sdch_filter.cc

Issue 1135373002: Updated NetLog::ParametersCallback & all related calbacks returning value as scoped_ptr<base::Value… Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « net/filter/filter.cc ('k') | net/ftp/ftp_ctrl_response_buffer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/filter/sdch_filter.cc
diff --git a/net/filter/sdch_filter.cc b/net/filter/sdch_filter.cc
index 858e101fe34976169942cdceb20b7d5a47bcbe58..5b0ff962644a5b937a5ee1dd96dc2d761e515c2a 100644
--- a/net/filter/sdch_filter.cc
+++ b/net/filter/sdch_filter.cc
@@ -90,14 +90,14 @@ const char* ResponseCorruptionDetectionCauseToString(
return cause_string;
}
-base::Value* NetLogSdchResponseCorruptionDetectionCallback(
+scoped_ptr<base::Value> NetLogSdchResponseCorruptionDetectionCallback(
ResponseCorruptionDetectionCause cause,
bool cached,
NetLogCaptureMode capture_mode) {
- base::DictionaryValue* dict = new base::DictionaryValue();
+ scoped_ptr<base::DictionaryValue> dict(new base::DictionaryValue());
dict->SetString("cause", ResponseCorruptionDetectionCauseToString(cause));
dict->SetBoolean("cached", cached);
- return dict;
+ return dict.Pass();
}
} // namespace
@@ -340,7 +340,7 @@ Filter::FilterStatus SdchFilter::ReadFilteredData(char* dest_buffer,
}
filter_context_.GetNetLog().AddEvent(
NetLog::TYPE_SDCH_RESPONSE_CORRUPTION_DETECTION,
- base::Bind(&NetLogSdchResponseCorruptionDetectionCallback, cause,
+ base::Bind(NetLogSdchResponseCorruptionDetectionCallback, cause,
filter_context_.IsCachedContent()));
if (decoding_status_ == PASS_THROUGH) {
@@ -563,7 +563,7 @@ void SdchFilter::LogSdchProblem(SdchProblemCode problem) {
SdchManager::SdchErrorRecovery(problem);
filter_context_.GetNetLog().AddEvent(
NetLog::TYPE_SDCH_DECODING_ERROR,
- base::Bind(&NetLogSdchResourceProblemCallback, problem));
+ base::Bind(NetLogSdchResourceProblemCallback, problem));
}
} // namespace net
« no previous file with comments | « net/filter/filter.cc ('k') | net/ftp/ftp_ctrl_response_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698