| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ | 5 #ifndef BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ |
| 6 #define BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ | 6 #define BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ |
| 7 | 7 |
| 8 #include <stdint.h> |
| 8 #include <sys/types.h> | 9 #include <sys/types.h> |
| 9 #include <vector> | 10 #include <vector> |
| 10 | 11 |
| 11 class Pickle; | 12 class Pickle; |
| 12 | 13 |
| 13 namespace base { | 14 namespace base { |
| 14 | 15 |
| 15 // Use sendmsg to write the given msg and include a vector | 16 // Use sendmsg to write the given msg and include a vector |
| 16 // of file descriptors. Returns true iff successful. | 17 // of file descriptors. Returns true iff successful. |
| 17 bool SendMsg(int fd, const void* msg, size_t length, | 18 bool SendMsg(int fd, const void* msg, size_t length, |
| (...skipping 14 matching lines...) Expand all Loading... |
| 32 // reply: buffer for the reply | 33 // reply: buffer for the reply |
| 33 // reply_len: size of |reply| | 34 // reply_len: size of |reply| |
| 34 // result_fd: (may be NULL) the file descriptor returned in the reply (if any) | 35 // result_fd: (may be NULL) the file descriptor returned in the reply (if any) |
| 35 // request: the bytes to send in the request | 36 // request: the bytes to send in the request |
| 36 ssize_t SendRecvMsg(int fd, uint8_t* reply, unsigned reply_len, int* result_fd, | 37 ssize_t SendRecvMsg(int fd, uint8_t* reply, unsigned reply_len, int* result_fd, |
| 37 const Pickle& request); | 38 const Pickle& request); |
| 38 | 39 |
| 39 } // namespace base | 40 } // namespace base |
| 40 | 41 |
| 41 #endif // BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ | 42 #endif // BASE_UNIX_DOMAIN_SOCKET_POSIX_H_ |
| OLD | NEW |