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

Unified Diff: tools/android/forwarder2/daemon.cc

Issue 15008004: Add device port unmapping support to forwarder2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address David's comments 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 | « build/android/pylib/forwarder.py ('k') | tools/android/forwarder2/device_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/android/forwarder2/daemon.cc
diff --git a/tools/android/forwarder2/daemon.cc b/tools/android/forwarder2/daemon.cc
index 0936ef4c1f76856e370fba840f82566963027232..c17cbc797416345b76b3a83c6009d4b5c06c614c 100644
--- a/tools/android/forwarder2/daemon.cc
+++ b/tools/android/forwarder2/daemon.cc
@@ -56,7 +56,7 @@ bool RunServerAcceptLoop(const std::string& welcome_message,
for (;;) {
scoped_ptr<Socket> client_socket(new Socket());
if (!server_socket->Accept(client_socket.get())) {
- if (server_socket->exited())
+ if (server_socket->DidReceiveEvent())
break;
PError("Accept()");
failed = true;
@@ -207,7 +207,7 @@ bool Daemon::SpawnIfNeeded() {
exit(1);
}
server_delegate_->Init();
- command_socket.set_exit_notifier_fd(get_exit_fd_callback_());
+ command_socket.AddEventFd(get_exit_fd_callback_());
exit(!RunServerAcceptLoop(identifier_, &command_socket,
server_delegate_));
}
« no previous file with comments | « build/android/pylib/forwarder.py ('k') | tools/android/forwarder2/device_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698