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

Unified Diff: third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc

Issue 975973002: Update mojo sdk to rev f68e697e389943cd9bf9652397312280e96b127a (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: shake fist at msvc Created 5 years, 10 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: third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc
diff --git a/third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc b/third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc
index 65ec8ef55e344b0c9e0ee778d26f3d2faa276c32..bee4b23bb70d2a044a54cf22f9e7db2e3b636041 100644
--- a/third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc
+++ b/third_party/mojo/src/mojo/edk/system/data_pipe_consumer_dispatcher.cc
@@ -23,6 +23,22 @@ Dispatcher::Type DataPipeConsumerDispatcher::GetType() const {
return kTypeDataPipeConsumer;
}
+// static
+scoped_refptr<DataPipeConsumerDispatcher>
+DataPipeConsumerDispatcher::Deserialize(Channel* channel,
+ const void* source,
+ size_t size) {
+ scoped_refptr<DataPipe> data_pipe;
+ if (!DataPipe::ConsumerDeserialize(channel, source, size, &data_pipe))
+ return nullptr;
+ DCHECK(data_pipe);
+
+ scoped_refptr<DataPipeConsumerDispatcher> dispatcher(
+ new DataPipeConsumerDispatcher());
+ dispatcher->Init(data_pipe);
+ return dispatcher;
+}
+
DataPipeConsumerDispatcher::~DataPipeConsumerDispatcher() {
// |Close()|/|CloseImplNoLock()| should have taken care of the pipe.
DCHECK(!data_pipe_);

Powered by Google App Engine
This is Rietveld 408576698