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

Unified Diff: content/shell/shell_message_filter.cc

Issue 13801004: [content shell] add scoped allow io to allow for reading files during layout tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/shell_message_filter.cc
diff --git a/content/shell/shell_message_filter.cc b/content/shell/shell_message_filter.cc
index 0aff194224aa5c745b0b75821cfe9a032c58c6d1..cb16871ac15ad8e894be0af8fdca5b0e19969db0 100644
--- a/content/shell/shell_message_filter.cc
+++ b/content/shell/shell_message_filter.cc
@@ -5,6 +5,7 @@
#include "content/shell/shell_message_filter.h"
#include "base/file_util.h"
+#include "base/threading/thread_restrictions.h"
#include "content/public/browser/child_process_security_policy.h"
#include "content/shell/shell_messages.h"
#include "content/shell/shell_network_delegate.h"
@@ -51,6 +52,7 @@ bool ShellMessageFilter::OnMessageReceived(const IPC::Message& message,
void ShellMessageFilter::OnReadFileToString(const base::FilePath& local_file,
std::string* contents) {
+ base::ThreadRestrictions::ScopedAllowIO allow_io;
file_util::ReadFileToString(local_file, contents);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698