Home
last modified time | relevance | path

Searched refs:unique_fd (Results 1 – 25 of 67) sorted by relevance

123

/system/tools/aidl/tests/
Daidl_test_client_file_descriptors.cpp29 using android::base::unique_fd;
53 bool DoWrite(const string& name, const unique_fd& fd, const string& buf) { in DoWrite()
72 bool DoRead(const string& name, const unique_fd& fd, const string& expected) { in DoRead()
93 bool DoPipe(unique_fd* read_side, unique_fd* write_side) { in DoPipe()
95 unique_fd return_fd; in DoPipe()
111 unique_fd return_fd; in ConfirmFileDescriptors()
112 unique_fd read_fd; in ConfirmFileDescriptors()
113 unique_fd write_fd; in ConfirmFileDescriptors()
142 vector<unique_fd> array; in ConfirmFileDescriptorArrays()
149 vector<unique_fd> repeated; in ConfirmFileDescriptorArrays()
[all …]
Daidl_test_service.cpp47 using android::base::unique_fd;
299 Status RepeatFileDescriptor(const unique_fd& read, in RepeatFileDescriptor()
300 unique_fd* _aidl_return) override { in RepeatFileDescriptor()
302 *_aidl_return = unique_fd(dup(read.get())); in RepeatFileDescriptor()
306 Status ReverseFileDescriptorArray(const vector<unique_fd>& input, in ReverseFileDescriptorArray()
307 vector<unique_fd>* repeated, in ReverseFileDescriptorArray()
308 vector<unique_fd>* _aidl_return) override { in ReverseFileDescriptorArray()
311 repeated->push_back(unique_fd(dup(item.get()))); in ReverseFileDescriptorArray()
312 _aidl_return->push_back(unique_fd(dup(item.get()))); in ReverseFileDescriptorArray()
/system/core/debuggerd/include/debuggerd/
Dutil.h29 ssize_t send_fd(int sockfd, const void* _Nonnull data, size_t len, android::base::unique_fd fd);
44 android::base::unique_fd* _Nullable out_fd);
46 bool Pipe(android::base::unique_fd* read, android::base::unique_fd* write);
Dtombstoned.h23 bool tombstoned_connect(pid_t pid, android::base::unique_fd* tombstoned_socket,
24 android::base::unique_fd* output_fd);
/system/core/debuggerd/
Ddebuggerd_test.cpp45 using android::base::unique_fd;
90 static void tombstoned_intercept(pid_t target_pid, unique_fd* intercept_fd, unique_fd* output_fd) { in tombstoned_intercept()
99 unique_fd output_pipe_write; in tombstoned_intercept()
144 unique_fd crasher_pipe;
145 unique_fd intercept_fd;
150 void StartIntercept(unique_fd* output_fd);
176 void CrasherTest::StartIntercept(unique_fd* output_fd) { in StartIntercept()
202 unique_fd read_pipe; in StartProcess()
203 unique_fd crasher_read_pipe; in StartProcess()
251 static void ConsumeFd(unique_fd fd, std::string* output) { in ConsumeFd()
[all …]
Dutil.cpp29 using android::base::unique_fd;
31 ssize_t send_fd(int sockfd, const void* data, size_t len, unique_fd fd) { in send_fd()
47 ssize_t recv_fd(int sockfd, void* _Nonnull data, size_t len, unique_fd* _Nullable out_fd) { in recv_fd()
68 unique_fd fd; in recv_fd()
92 bool Pipe(unique_fd* read, unique_fd* write) { in Pipe()
Dtombstoned_client.cpp31 using android::base::unique_fd;
33 bool tombstoned_connect(pid_t pid, unique_fd* tombstoned_socket, unique_fd* output_fd) { in tombstoned_connect()
34 unique_fd sockfd(socket_local_client(kTombstonedCrashSocketName, in tombstoned_connect()
51 unique_fd tmp_output_fd; in tombstoned_connect()
Ddebuggerd.cpp33 using android::base::unique_fd;
42 static std::thread spawn_redirect_thread(unique_fd fd) { in spawn_redirect_thread()
69 unique_fd piperead, pipewrite; in main()
Dcrash_dump.cpp57 using android::base::unique_fd;
105 android::base::unique_fd amfd(socket_local_client( in activity_manager_notify()
157 unique_fd& tombstoned_socket, unique_fd& output_fd, in abort_handler()
200 unique_fd tombstoned_socket; in main()
201 unique_fd output_fd; in main()
334 unique_fd devnull(TEMP_FAILURE_RETRY(open("/dev/null", O_RDWR))); in main()
/system/core/adb/
Dshell_service.cpp126 bool CreateSocketpair(unique_fd* fd1, unique_fd* fd2) { in CreateSocketpair()
160 int OpenPtyChildFd(const char* pts_name, unique_fd* error_sfd);
166 unique_fd* SelectLoop(fd_set* master_read_set_ptr,
171 unique_fd* PassInput();
172 unique_fd* PassOutput(unique_fd* sfd, ShellProtocol::Id id);
180 unique_fd local_socket_sfd_;
183 unique_fd stdinout_sfd_, stderr_sfd_, protocol_sfd_;
215 unique_fd child_stdinout_sfd, child_stderr_sfd; in ForkAndExec()
216 unique_fd parent_error_sfd, child_error_sfd; in ForkAndExec()
405 int Subprocess::OpenPtyChildFd(const char* pts_name, unique_fd* error_sfd) { in OpenPtyChildFd()
[all …]
/system/core/libcutils/tests/
DAshmemTest.cpp22 using android::base::unique_fd;
24 void TestCreateRegion(size_t size, unique_fd &fd, int prot) { in TestCreateRegion()
25 fd = unique_fd(ashmem_create_region(nullptr, size)); in TestCreateRegion()
32 void TestMmap(const unique_fd &fd, size_t size, int prot, void **region) { in TestMmap()
37 void TestProtDenied(const unique_fd &fd, size_t size, int prot) { in TestProtDenied()
52 unique_fd fd; in TEST()
74 unique_fd fd; in TEST()
105 unique_fd fd; in TEST()
121 unique_fd fd; in TEST()
144 unique_fd fd[nRegions]; in TEST()
/system/core/debuggerd/tombstoned/
Dintercept_manager.h37 android::base::unique_fd sockfd;
40 android::base::unique_fd output_fd;
53 bool GetIntercept(pid_t pid, android::base::unique_fd* out_fd);
Dtombstoned.cpp44 using android::base::unique_fd;
61 unique_fd crash_fd;
108 static std::pair<unique_fd, std::string> get_tombstone() { in get_tombstone()
113 unique_fd result; in get_tombstone()
130 unique_fd output_fd; in perform_request()
/system/core/debuggerd/client/
Ddebuggerd_client_test.cpp37 using android::base::unique_fd;
60 unique_fd pipe_read, pipe_write; in TEST()
94 unique_fd pipe_read, pipe_write; in TEST()
108 unique_fd output_read, output_write; in TEST()
Ddebuggerd_client.cpp42 using android::base::unique_fd;
62 bool debuggerd_trigger_dump(pid_t pid, unique_fd output_fd, DebuggerdDumpType dump_type, in debuggerd_trigger_dump()
65 unique_fd sockfd; in debuggerd_trigger_dump()
113 unique_fd pipe_read, pipe_write; in debuggerd_trigger_dump()
231 android::base::unique_fd copy(dup(fd)); in dump_backtrace_to_file_timeout()
/system/connectivity/wificond/tests/
Dlooper_backed_event_loop_unittest.cpp36 android::base::unique_fd send_fd;
37 android::base::unique_fd receive_fd;
43 receive_fd = android::base::unique_fd(fds[0]); in Pipe()
44 send_fd = android::base::unique_fd(fds[1]); in Pipe()
Dshell_utils.cpp31 using android::base::unique_fd;
64 unique_fd read_fd(fds[0]); in RunShellCommand()
65 unique_fd write_fd(fds[1]); in RunShellCommand()
/system/core/libappfuse/include/libappfuse/
DFuseAppLoop.h47 FuseAppLoop(base::unique_fd&& fd);
60 base::unique_fd fd_;
61 base::unique_fd break_fd_;
DEpollController.h32 explicit EpollController(base::unique_fd&& poll_fd);
44 base::unique_fd poll_fd_;
DFuseBridgeLoop.h51 bool AddBridge(int mount_id, base::unique_fd dev_fd, base::unique_fd proxy_fd);
/system/core/libappfuse/
DFuseBridgeLoop.cc64 FuseBridgeEntry(int mount_id, base::unique_fd&& dev_fd, base::unique_fd&& proxy_fd) in FuseBridgeEntry()
225 base::unique_fd device_fd_;
226 base::unique_fd proxy_fd_;
244 BridgeEpollController(base::unique_fd&& poll_fd) : EpollController(std::move(poll_fd)) {} in BridgeEpollController()
297 base::unique_fd epoll_fd(epoll_create1(/* no flag */ 0)); in FuseBridgeLoop()
308 bool FuseBridgeLoop::AddBridge(int mount_id, base::unique_fd dev_fd, base::unique_fd proxy_fd) { in AddBridge()
/system/core/debuggerd/handler/
Ddebuggerd_fallback.cpp52 using android::base::unique_fd;
153 unique_fd tombstone_socket, output_fd; in trace_handler()
168 unique_fd pipe_read, pipe_write; in trace_handler()
216 unique_fd tombstone_socket, output_fd; in crash_handler()
/system/connectivity/wificond/net/
Dnetlink_manager.h231 bool SetupSocket(android::base::unique_fd* netlink_fd);
232 bool WatchSocket(android::base::unique_fd* netlink_fd);
253 android::base::unique_fd sync_netlink_fd_;
254 android::base::unique_fd async_netlink_fd_;
/system/core/libappfuse/tests/
DFuseBufferTest.cc33 void OpenTempFile(android::base::unique_fd* fd) { in OpenTempFile()
41 android::base::unique_fd fd; in TestReadInvalidLength()
54 android::base::unique_fd fd; in TestWriteInvalidLength()
66 android::base::unique_fd fd; in TEST()
196 base::unique_fd fds[2]; in TEST()
/system/vold/
DLoop.cpp46 using android::base::unique_fd;
240 unique_fd ctl_fd(open("/dev/loop-control", O_RDWR | O_CLOEXEC)); in create()
254 unique_fd target_fd(open(target.c_str(), O_RDWR | O_CLOEXEC)); in create()
259 unique_fd device_fd(open(out_device.c_str(), O_RDWR | O_CLOEXEC)); in create()
298 unique_fd fd(open(file, O_CREAT | O_WRONLY | O_TRUNC | O_CLOEXEC, 0600)); in createImageFile()

123