| 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 "sandbox/linux/syscall_broker/broker_client.h" | 5 #include "sandbox/linux/syscall_broker/broker_client.h" |
| 6 | 6 |
| 7 #include <errno.h> | 7 #include <errno.h> |
| 8 #include <fcntl.h> | 8 #include <fcntl.h> |
| 9 #include <stddef.h> | 9 #include <sys/stat.h> |
| 10 #include <stdint.h> | |
| 11 #include <sys/socket.h> | 10 #include <sys/socket.h> |
| 12 #include <sys/stat.h> | |
| 13 #include <sys/types.h> | 11 #include <sys/types.h> |
| 14 #include <utility> | 12 #include <utility> |
| 15 | 13 |
| 14 #include "build/build_config.h" |
| 16 #include "base/logging.h" | 15 #include "base/logging.h" |
| 17 #include "base/pickle.h" | 16 #include "base/pickle.h" |
| 18 #include "base/posix/unix_domain_socket_linux.h" | 17 #include "base/posix/unix_domain_socket_linux.h" |
| 19 #include "build/build_config.h" | |
| 20 #include "sandbox/linux/syscall_broker/broker_channel.h" | 18 #include "sandbox/linux/syscall_broker/broker_channel.h" |
| 21 #include "sandbox/linux/syscall_broker/broker_common.h" | 19 #include "sandbox/linux/syscall_broker/broker_common.h" |
| 22 #include "sandbox/linux/syscall_broker/broker_policy.h" | 20 #include "sandbox/linux/syscall_broker/broker_policy.h" |
| 23 | 21 |
| 24 #if defined(OS_ANDROID) && !defined(MSG_CMSG_CLOEXEC) | 22 #if defined(OS_ANDROID) && !defined(MSG_CMSG_CLOEXEC) |
| 25 #define MSG_CMSG_CLOEXEC 0x40000000 | 23 #define MSG_CMSG_CLOEXEC 0x40000000 |
| 26 #endif | 24 #endif |
| 27 | 25 |
| 28 namespace sandbox { | 26 namespace sandbox { |
| 29 | 27 |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 return PathAndFlagsSyscall(COMMAND_ACCESS, pathname, mode); | 135 return PathAndFlagsSyscall(COMMAND_ACCESS, pathname, mode); |
| 138 } | 136 } |
| 139 | 137 |
| 140 int BrokerClient::Open(const char* pathname, int flags) const { | 138 int BrokerClient::Open(const char* pathname, int flags) const { |
| 141 return PathAndFlagsSyscall(COMMAND_OPEN, pathname, flags); | 139 return PathAndFlagsSyscall(COMMAND_OPEN, pathname, flags); |
| 142 } | 140 } |
| 143 | 141 |
| 144 } // namespace syscall_broker | 142 } // namespace syscall_broker |
| 145 | 143 |
| 146 } // namespace sandbox | 144 } // namespace sandbox |
| OLD | NEW |