diff options
author | gVisor bot <gvisor-bot@google.com> | 2019-10-02 14:51:04 -0700 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2019-10-02 14:51:04 -0700 |
commit | cde771183754f74b1e43f76ee2a3f227c15d39bd (patch) | |
tree | 858df35a22412816583ba7668778deb3ad95d848 /test/syscalls/linux/ip_socket_test_util.cc | |
parent | 61e40819d9db05aecb8b36a46d529bd8fe425dcf (diff) | |
parent | 329b6653ffbb29b47409a923a7fbb3bd3aff074f (diff) |
Merge pull request #865 from tanjianfeng:fix-829
PiperOrigin-RevId: 272522508
Diffstat (limited to 'test/syscalls/linux/ip_socket_test_util.cc')
-rw-r--r-- | test/syscalls/linux/ip_socket_test_util.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/syscalls/linux/ip_socket_test_util.cc b/test/syscalls/linux/ip_socket_test_util.cc index 410b42a47..f81ed22c8 100644 --- a/test/syscalls/linux/ip_socket_test_util.cc +++ b/test/syscalls/linux/ip_socket_test_util.cc @@ -60,6 +60,14 @@ SocketPairKind IPv6TCPAcceptBindSocketPair(int type) { /* dual_stack = */ false)}; } +SocketKind IPv6TCPUnboundSocket(int type) { + std::string description = + absl::StrCat(DescribeSocketType(type), "IPv6 TCP socket"); + return SocketKind{ + description, AF_INET6, type | SOCK_STREAM, IPPROTO_TCP, + UnboundSocketCreator(AF_INET6, type | SOCK_STREAM, IPPROTO_TCP)}; +} + SocketPairKind IPv4TCPAcceptBindSocketPair(int type) { std::string description = absl::StrCat(DescribeSocketType(type), "connected IPv4 TCP socket"); |