OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 <sys/socket.h> | 5 #include <sys/socket.h> |
6 #include <sys/types.h> | 6 #include <sys/types.h> |
7 #include <unistd.h> | 7 #include <unistd.h> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
11 #include "base/file_util.h" | 11 #include "base/files/file_util.h" |
12 #include "base/files/scoped_file.h" | 12 #include "base/files/scoped_file.h" |
13 #include "base/memory/scoped_vector.h" | 13 #include "base/memory/scoped_vector.h" |
14 #include "base/pickle.h" | 14 #include "base/pickle.h" |
15 #include "base/posix/unix_domain_socket_linux.h" | 15 #include "base/posix/unix_domain_socket_linux.h" |
16 #include "base/synchronization/waitable_event.h" | 16 #include "base/synchronization/waitable_event.h" |
17 #include "base/threading/thread.h" | 17 #include "base/threading/thread.h" |
18 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
19 | 19 |
20 namespace base { | 20 namespace base { |
21 | 21 |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 const ssize_t nread = UnixDomainSocket::RecvMsgWithPid( | 152 const ssize_t nread = UnixDomainSocket::RecvMsgWithPid( |
153 recv_sock.get(), &ch, sizeof(ch), &recv_fds, &sender_pid); | 153 recv_sock.get(), &ch, sizeof(ch), &recv_fds, &sender_pid); |
154 ASSERT_EQ(0, nread); | 154 ASSERT_EQ(0, nread); |
155 ASSERT_EQ(-1, sender_pid); | 155 ASSERT_EQ(-1, sender_pid); |
156 ASSERT_EQ(0U, recv_fds.size()); | 156 ASSERT_EQ(0U, recv_fds.size()); |
157 } | 157 } |
158 | 158 |
159 } // namespace | 159 } // namespace |
160 | 160 |
161 } // namespace base | 161 } // namespace base |
OLD | NEW |