OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ | 5 #ifndef MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ |
6 #define MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ | 6 #define MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <algorithm> // For |std::swap()|. | 9 #include <algorithm> // For |std::swap()|. |
10 #include <utility> | 10 #include <utility> |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 // The object hasn't been bound. | 165 // The object hasn't been bound. |
166 if (!waiter_) { | 166 if (!waiter_) { |
167 DCHECK(!handle_.is_valid()); | 167 DCHECK(!handle_.is_valid()); |
168 return; | 168 return; |
169 } | 169 } |
170 | 170 |
171 FilterChain filters; | 171 FilterChain filters; |
172 filters.Append<MessageHeaderValidator>(); | 172 filters.Append<MessageHeaderValidator>(); |
173 filters.Append<typename Interface::ResponseValidator_>(); | 173 filters.Append<typename Interface::ResponseValidator_>(); |
174 | 174 |
175 router_ = new Router(std::move(handle_), std::move(filters), waiter_); | 175 router_ = |
| 176 new Router(std::move(handle_), std::move(filters), false, waiter_); |
176 waiter_ = nullptr; | 177 waiter_ = nullptr; |
177 | 178 |
178 proxy_ = new Proxy(router_); | 179 proxy_ = new Proxy(router_); |
179 } | 180 } |
180 | 181 |
181 Proxy* proxy_; | 182 Proxy* proxy_; |
182 Router* router_; | 183 Router* router_; |
183 | 184 |
184 // |proxy_| and |router_| are not initialized until read/write with the | 185 // |proxy_| and |router_| are not initialized until read/write with the |
185 // message pipe handle is needed. |handle_| and |waiter_| are valid between | 186 // message pipe handle is needed. |handle_| and |waiter_| are valid between |
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
357 | 358 |
358 uint32_t version_; | 359 uint32_t version_; |
359 | 360 |
360 DISALLOW_COPY_AND_ASSIGN(InterfacePtrState); | 361 DISALLOW_COPY_AND_ASSIGN(InterfacePtrState); |
361 }; | 362 }; |
362 | 363 |
363 } // namespace internal | 364 } // namespace internal |
364 } // namespace mojo | 365 } // namespace mojo |
365 | 366 |
366 #endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ | 367 #endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_INTERFACE_PTR_STATE_H_ |
OLD | NEW |