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

Unified Diff: mojo/message_pump/message_pump_mojo.cc

Issue 1475983004: Revert making HandleWatcher block until no longer waiting on pipe (r285266). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update comment (undo change in r283888 Created 5 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
« no previous file with comments | « mojo/message_pump/handle_watcher.cc ('k') | mojo/public/c/environment/async_waiter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/message_pump/message_pump_mojo.cc
diff --git a/mojo/message_pump/message_pump_mojo.cc b/mojo/message_pump/message_pump_mojo.cc
index cd220179b2abc0e3d7b6c254af5f4c21a981c7c6..12f9cc163c444a3f6303a2d380a66daa478c7ac6 100644
--- a/mojo/message_pump/message_pump_mojo.cc
+++ b/mojo/message_pump/message_pump_mojo.cc
@@ -202,6 +202,7 @@ bool MessagePumpMojo::DoInternalWork(const RunState& run_state, bool block) {
switch (result) {
case MOJO_RESULT_CANCELLED:
case MOJO_RESULT_FAILED_PRECONDITION:
+ case MOJO_RESULT_INVALID_ARGUMENT:
RemoveInvalidHandle(wait_state, result, wait_many_result.index);
break;
case MOJO_RESULT_DEADLINE_EXCEEDED:
@@ -249,7 +250,8 @@ void MessagePumpMojo::RemoveInvalidHandle(const WaitState& wait_state,
MojoResult result,
uint32_t index) {
// TODO(sky): deal with control pipe going bad.
- CHECK(result == MOJO_RESULT_FAILED_PRECONDITION ||
+ CHECK(result == MOJO_RESULT_INVALID_ARGUMENT ||
+ result == MOJO_RESULT_FAILED_PRECONDITION ||
result == MOJO_RESULT_CANCELLED);
CHECK_NE(index, 0u); // Indicates the control pipe went bad.
« no previous file with comments | « mojo/message_pump/handle_watcher.cc ('k') | mojo/public/c/environment/async_waiter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698