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

Unified Diff: chrome/test/chromedriver/server/chromedriver_server.cc

Issue 2104363004: Remove remaining calls to deprecated MessageLoop methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: CR gab Created 4 years, 5 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: chrome/test/chromedriver/server/chromedriver_server.cc
diff --git a/chrome/test/chromedriver/server/chromedriver_server.cc b/chrome/test/chromedriver/server/chromedriver_server.cc
index 3146c31af9a59ffefdc765668e886e0bac3e428a..79d25fc4d70e150b6ba5c34f5d771d46b0da9b00 100644
--- a/chrome/test/chromedriver/server/chromedriver_server.cc
+++ b/chrome/test/chromedriver/server/chromedriver_server.cc
@@ -22,6 +22,7 @@
#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
@@ -207,7 +208,7 @@ void RunServer(uint16_t port,
HttpRequestHandlerFunc handle_request_func =
base::Bind(&HandleRequestOnCmdThread, &handler, whitelisted_ips);
- io_thread.message_loop()->PostTask(
+ io_thread.message_loop()->task_runner()->PostTask(
FROM_HERE,
base::Bind(&StartServerOnIOThread, port, allow_remote,
base::Bind(&HandleRequestOnIOThread, cmd_loop.task_runner(),
@@ -218,8 +219,8 @@ void RunServer(uint16_t port,
// destroyed, which waits until all pending tasks have been completed.
// This assumes the response is sent synchronously as part of the IO task.
cmd_run_loop.Run();
- io_thread.message_loop()
- ->PostTask(FROM_HERE, base::Bind(&StopServerOnIOThread));
+ io_thread.message_loop()->task_runner()->PostTask(
+ FROM_HERE, base::Bind(&StopServerOnIOThread));
}
} // namespace

Powered by Google App Engine
This is Rietveld 408576698