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

Unified Diff: content/browser/renderer_host/render_message_filter.cc

Issue 33053002: Pepper: Move FileIO host from renderer to browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 1 month 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: content/browser/renderer_host/render_message_filter.cc
diff --git a/content/browser/renderer_host/render_message_filter.cc b/content/browser/renderer_host/render_message_filter.cc
index 03d8798e67cb229229951bc55335d0b6bf3bfb8c..48866d7a25708946653f4c12739524838e691096 100644
--- a/content/browser/renderer_host/render_message_filter.cc
+++ b/content/browser/renderer_host/render_message_filter.cc
@@ -389,7 +389,6 @@ bool RenderMessageFilter::OnMessageReceived(const IPC::Message& message,
OnDidDeleteOutOfProcessPepperInstance)
IPC_MESSAGE_HANDLER(ViewHostMsg_OpenChannelToPpapiBroker,
OnOpenChannelToPpapiBroker)
- IPC_MESSAGE_HANDLER(ViewHostMsg_AsyncOpenPepperFile, OnAsyncOpenPepperFile)
#endif
IPC_MESSAGE_HANDLER_GENERIC(ViewHostMsg_UpdateRect,
render_widget_helper_->DidReceiveBackingStoreMsg(message))
@@ -440,8 +439,6 @@ base::TaskRunner* RenderMessageFilter::OverrideTaskRunnerForMessage(
if (message.type() == ViewHostMsg_GetAudioHardwareConfig::ID)
return audio_manager_->GetMessageLoop().get();
#endif
- if (message.type() == ViewHostMsg_AsyncOpenPepperFile::ID)
- return BrowserThread::GetBlockingPool();
return NULL;
}
@@ -988,33 +985,6 @@ void RenderMessageFilter::OnKeygenOnWorkerThread(
Send(reply_msg);
}
-void RenderMessageFilter::OnAsyncOpenPepperFile(int routing_id,
- const base::FilePath& path,
- int pp_open_flags) {
- int platform_file_flags = 0;
- if (!CanOpenWithPepperFlags(pp_open_flags, render_process_id_, path) ||
- !ppapi::PepperFileOpenFlagsToPlatformFileFlags(
- pp_open_flags, &platform_file_flags)) {
- DLOG(ERROR) <<
- "Bad pp_open_flags in ViewMsgHost_AsyncOpenPepperFile message: " <<
- pp_open_flags;
- RecordAction(UserMetricsAction("BadMessageTerminate_AOF"));
- BadMessageReceived();
- return;
- }
-
- base::PlatformFileError error_code = base::PLATFORM_FILE_OK;
- base::PlatformFile file = base::CreatePlatformFile(
- path, platform_file_flags, NULL, &error_code);
- IPC::PlatformFileForTransit file_for_transit =
- file != base::kInvalidPlatformFileValue ?
- IPC::GetFileHandleForProcess(file, PeerHandle(), true) :
- IPC::InvalidPlatformFileForTransit();
-
- Send(new ViewMsg_AsyncOpenPepperFile_ACK(
- routing_id, error_code, file_for_transit));
-}
-
void RenderMessageFilter::OnMediaLogEvents(
const std::vector<media::MediaLogEvent>& events) {
if (media_internals_)
« no previous file with comments | « content/browser/renderer_host/render_message_filter.h ('k') | content/child/fileapi/file_system_dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698