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

Side by Side Diff: mojo/edk/system/data_pipe.cc

Issue 1423713009: EDK: Move ref counting classes to mojo/edk/util. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « mojo/edk/system/data_pipe.h ('k') | mojo/edk/system/data_pipe_consumer_dispatcher.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "mojo/edk/system/data_pipe.h" 5 #include "mojo/edk/system/data_pipe.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <limits> 10 #include <limits>
11 #include <memory> 11 #include <memory>
12 #include <utility> 12 #include <utility>
13 13
14 #include "base/logging.h" 14 #include "base/logging.h"
15 #include "base/memory/aligned_memory.h" 15 #include "base/memory/aligned_memory.h"
16 #include "mojo/edk/system/awakable_list.h" 16 #include "mojo/edk/system/awakable_list.h"
17 #include "mojo/edk/system/channel.h" 17 #include "mojo/edk/system/channel.h"
18 #include "mojo/edk/system/configuration.h" 18 #include "mojo/edk/system/configuration.h"
19 #include "mojo/edk/system/data_pipe_impl.h" 19 #include "mojo/edk/system/data_pipe_impl.h"
20 #include "mojo/edk/system/incoming_endpoint.h" 20 #include "mojo/edk/system/incoming_endpoint.h"
21 #include "mojo/edk/system/local_data_pipe_impl.h" 21 #include "mojo/edk/system/local_data_pipe_impl.h"
22 #include "mojo/edk/system/memory.h" 22 #include "mojo/edk/system/memory.h"
23 #include "mojo/edk/system/options_validation.h" 23 #include "mojo/edk/system/options_validation.h"
24 #include "mojo/edk/system/remote_consumer_data_pipe_impl.h" 24 #include "mojo/edk/system/remote_consumer_data_pipe_impl.h"
25 #include "mojo/edk/system/remote_producer_data_pipe_impl.h" 25 #include "mojo/edk/system/remote_producer_data_pipe_impl.h"
26 #include "mojo/edk/util/make_unique.h" 26 #include "mojo/edk/util/make_unique.h"
27 27
28 using mojo::util::RefPtr;
29
28 namespace mojo { 30 namespace mojo {
29 namespace system { 31 namespace system {
30 32
31 // static 33 // static
32 MojoCreateDataPipeOptions DataPipe::GetDefaultCreateOptions() { 34 MojoCreateDataPipeOptions DataPipe::GetDefaultCreateOptions() {
33 MojoCreateDataPipeOptions result = { 35 MojoCreateDataPipeOptions result = {
34 static_cast<uint32_t>(sizeof(MojoCreateDataPipeOptions)), 36 static_cast<uint32_t>(sizeof(MojoCreateDataPipeOptions)),
35 MOJO_CREATE_DATA_PIPE_OPTIONS_FLAG_NONE, 37 MOJO_CREATE_DATA_PIPE_OPTIONS_FLAG_NONE,
36 1u, 38 1u,
37 static_cast<uint32_t>( 39 static_cast<uint32_t>(
(...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after
803 SetProducerClosedNoLock(); 805 SetProducerClosedNoLock();
804 } 806 }
805 807
806 void DataPipe::SetConsumerClosed() { 808 void DataPipe::SetConsumerClosed() {
807 MutexLocker locker(&mutex_); 809 MutexLocker locker(&mutex_);
808 SetConsumerClosedNoLock(); 810 SetConsumerClosedNoLock();
809 } 811 }
810 812
811 } // namespace system 813 } // namespace system
812 } // namespace mojo 814 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/edk/system/data_pipe.h ('k') | mojo/edk/system/data_pipe_consumer_dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698