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

Unified Diff: chrome_frame/test/test_server.cc

Issue 15935013: chrome_frame: Use base::MessageLoop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix license Created 7 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 | « chrome_frame/test/test_server.h ('k') | chrome_frame/test/test_server_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/test/test_server.cc
diff --git a/chrome_frame/test/test_server.cc b/chrome_frame/test/test_server.cc
index 181209e34027886bd72b910cefc6fd1803c58495..dd8d9bcbc5256508226cb8177c696b2be2241835 100644
--- a/chrome_frame/test/test_server.cc
+++ b/chrome_frame/test/test_server.cc
@@ -38,7 +38,8 @@ void Request::ParseHeaders(const std::string& headers) {
if (pos != std::string::npos) {
headers_ = headers.substr(pos + 2);
- base::StringTokenizer tokenizer(headers.begin(), headers.begin() + pos, " ");
+ base::StringTokenizer tokenizer(
+ headers.begin(), headers.begin() + pos, " ");
std::string* parse[] = { &method_, &path_, &version_ };
int field = 0;
while (tokenizer.GetNext() && field < arraysize(parse)) {
@@ -153,7 +154,8 @@ SimpleWebServer::~SimpleWebServer() {
}
void SimpleWebServer::Construct(const std::string& address, int port) {
- CHECK(MessageLoop::current()) << "SimpleWebServer requires a message loop";
+ CHECK(base::MessageLoop::current())
+ << "SimpleWebServer requires a message loop";
net::EnsureWinsockInit();
AddResponse(&quit_);
host_ = address;
@@ -356,7 +358,7 @@ void ConfigurableConnection::SendChunk() {
cur_pos_ += bytes_to_send;
if (cur_pos_ < size) {
- MessageLoop::current()->PostDelayedTask(
+ base::MessageLoop::current()->PostDelayedTask(
FROM_HERE, base::Bind(&ConfigurableConnection::SendChunk, this),
base::TimeDelta::FromMilliseconds(options_.timeout_));
} else {
@@ -393,7 +395,7 @@ void ConfigurableConnection::SendWithOptions(const std::string& headers,
socket_->Send(content);
// Post a task to close the socket since StreamListenSocket doesn't like
// instances to go away from within its callbacks.
- MessageLoop::current()->PostTask(
+ base::MessageLoop::current()->PostTask(
FROM_HERE, base::Bind(&ConfigurableConnection::Close, this));
return;
@@ -412,7 +414,7 @@ void ConfigurableConnection::SendWithOptions(const std::string& headers,
data_.append("\r\n");
}
- MessageLoop::current()->PostDelayedTask(
+ base::MessageLoop::current()->PostDelayedTask(
FROM_HERE, base::Bind(&ConfigurableConnection::SendChunk, this),
base::TimeDelta::FromMilliseconds(options.timeout_));
}
« no previous file with comments | « chrome_frame/test/test_server.h ('k') | chrome_frame/test/test_server_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698