| OLD | NEW |
| 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_consumer_dispatcher.h" | 5 #include "mojo/edk/system/data_pipe_consumer_dispatcher.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "mojo/edk/system/data_pipe.h" | 10 #include "mojo/edk/system/data_pipe.h" |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 size_t* actual_size, | 223 size_t* actual_size, |
| 224 std::vector<ScopedPlatformHandle>* platform_handles) { | 224 std::vector<ScopedPlatformHandle>* platform_handles) { |
| 225 AssertHasOneRef(); // Only one ref => no need to take the lock. | 225 AssertHasOneRef(); // Only one ref => no need to take the lock. |
| 226 | 226 |
| 227 bool rv = data_pipe_->ConsumerEndSerialize(channel, destination, actual_size, | 227 bool rv = data_pipe_->ConsumerEndSerialize(channel, destination, actual_size, |
| 228 platform_handles); | 228 platform_handles); |
| 229 data_pipe_ = nullptr; | 229 data_pipe_ = nullptr; |
| 230 return rv; | 230 return rv; |
| 231 } | 231 } |
| 232 | 232 |
| 233 bool DataPipeConsumerDispatcher::IsBusyNoLock() const { | |
| 234 mutex().AssertHeld(); | |
| 235 return data_pipe_->ConsumerIsBusy(); | |
| 236 } | |
| 237 | |
| 238 } // namespace system | 233 } // namespace system |
| 239 } // namespace mojo | 234 } // namespace mojo |
| OLD | NEW |