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

Unified Diff: webkit/plugins/ppapi/ppb_url_response_info_impl.cc

Issue 7706021: Convert FileRefImpl and URLRequestInfo to shared_impl. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Tests fixed Created 9 years, 4 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
Index: webkit/plugins/ppapi/ppb_url_response_info_impl.cc
diff --git a/webkit/plugins/ppapi/ppb_url_response_info_impl.cc b/webkit/plugins/ppapi/ppb_url_response_info_impl.cc
index fa35c0d2fa2b1126aec8735834f4754fd81f3681..eb5e2ff77b6fc5ba84e3a5da883ccc45c569790b 100644
--- a/webkit/plugins/ppapi/ppb_url_response_info_impl.cc
+++ b/webkit/plugins/ppapi/ppb_url_response_info_impl.cc
@@ -74,8 +74,8 @@ bool PPB_URLResponseInfo_Impl::Initialize(const WebURLResponse& response) {
WebString file_path = response.downloadFilePath();
if (!file_path.isEmpty()) {
- body_ = new PPB_FileRef_Impl(pp_instance(),
- webkit_glue::WebStringToFilePath(file_path));
+ body_ = PPB_FileRef_Impl::CreateExternal(
+ pp_instance(), webkit_glue::WebStringToFilePath(file_path));
}
return true;
}
@@ -114,7 +114,6 @@ PP_Var PPB_URLResponseInfo_Impl::GetProperty(PP_URLResponseProperty property) {
PP_Resource PPB_URLResponseInfo_Impl::GetBodyAsFileRef() {
if (!body_.get())
return 0;
- body_->AddRef(); // AddRef for the caller.
return body_->GetReference();
}

Powered by Google App Engine
This is Rietveld 408576698