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 #include "device/bluetooth/dbus/fake_bluetooth_media_transport_client.h" | 5 #include "device/bluetooth/dbus/fake_bluetooth_media_transport_client.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 #include <sys/socket.h> |
7 #include <unistd.h> | 9 #include <unistd.h> |
8 #include <sys/socket.h> | |
9 | 10 |
10 #include <sstream> | 11 #include <sstream> |
11 | 12 |
12 #include "base/bind.h" | 13 #include "base/bind.h" |
| 14 #include "base/macros.h" |
13 #include "base/stl_util.h" | 15 #include "base/stl_util.h" |
14 #include "dbus/file_descriptor.h" | 16 #include "dbus/file_descriptor.h" |
15 #include "device/bluetooth/dbus/bluetooth_media_client.h" | 17 #include "device/bluetooth/dbus/bluetooth_media_client.h" |
16 #include "device/bluetooth/dbus/bluez_dbus_manager.h" | 18 #include "device/bluetooth/dbus/bluez_dbus_manager.h" |
17 #include "device/bluetooth/dbus/fake_bluetooth_adapter_client.h" | 19 #include "device/bluetooth/dbus/fake_bluetooth_adapter_client.h" |
18 #include "device/bluetooth/dbus/fake_bluetooth_media_client.h" | 20 #include "device/bluetooth/dbus/fake_bluetooth_media_client.h" |
19 #include "device/bluetooth/dbus/fake_bluetooth_media_endpoint_service_provider.h
" | 21 #include "device/bluetooth/dbus/fake_bluetooth_media_endpoint_service_provider.h
" |
20 | 22 |
21 using dbus::ObjectPath; | 23 using dbus::ObjectPath; |
22 | 24 |
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
319 } | 321 } |
320 DCHECK((fds[0] > kInvalidFd) && (fds[1] > kInvalidFd)); | 322 DCHECK((fds[0] > kInvalidFd) && (fds[1] > kInvalidFd)); |
321 transport->input_fd.reset(new base::File(fds[0])); | 323 transport->input_fd.reset(new base::File(fds[0])); |
322 | 324 |
323 dbus::FileDescriptor out_fd(fds[1]); | 325 dbus::FileDescriptor out_fd(fds[1]); |
324 callback.Run(&out_fd, kDefaultReadMtu, kDefaultWriteMtu); | 326 callback.Run(&out_fd, kDefaultReadMtu, kDefaultWriteMtu); |
325 SetState(endpoint_path, "active"); | 327 SetState(endpoint_path, "active"); |
326 } | 328 } |
327 | 329 |
328 } // namespace bluez | 330 } // namespace bluez |
OLD | NEW |