| Index: mojo/edk/system/data_pipe_consumer_dispatcher.cc
|
| diff --git a/mojo/edk/system/data_pipe_consumer_dispatcher.cc b/mojo/edk/system/data_pipe_consumer_dispatcher.cc
|
| index 0e73f9b36667fb28bd5d50b7412d10792ae65dfa..6f86663be988c1964ad5c18fb5593d676eb389e4 100644
|
| --- a/mojo/edk/system/data_pipe_consumer_dispatcher.cc
|
| +++ b/mojo/edk/system/data_pipe_consumer_dispatcher.cc
|
| @@ -116,8 +116,11 @@ DataPipeConsumerDispatcher::DataPipeConsumerDispatcher(
|
| }
|
|
|
| DataPipeConsumerDispatcher::~DataPipeConsumerDispatcher() {
|
| - // |Close()|/|CloseImplNoLock()| should have taken care of the channel.
|
| - DCHECK(!channel_);
|
| + // See comment in ~MessagePipeDispatcher.
|
| + if (channel_ && internal::g_io_thread_task_runner->RunsTasksOnCurrentThread())
|
| + channel_->Shutdown();
|
| + else
|
| + DCHECK(!channel_);
|
| }
|
|
|
| void DataPipeConsumerDispatcher::CancelAllAwakablesNoLock() {
|
|
|