summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-08-28 19:28:35 -0700
committerElliott Hughes <enh@google.com>2014-08-28 19:28:35 -0700
commitf6824b26ae06cc4e9964dd0d803676731ae7dbe0 (patch)
treec0daf0fd508da1f98cd4750d38031e8a2802917c
parent29f06943a19ef2271a08f4223f597a3383f0d9c0 (diff)
downloadbionic-f6824b26ae06cc4e9964dd0d803676731ae7dbe0.zip
bionic-f6824b26ae06cc4e9964dd0d803676731ae7dbe0.tar.gz
bionic-f6824b26ae06cc4e9964dd0d803676731ae7dbe0.tar.bz2
The host prebuilt glibc is 2.11, so remove workarounds for 2.9.
Change-Id: I1072fcebc8b3018580a9d069fe6eca9c4e74e865
-rw-r--r--tests/sys_socket_test.cpp17
1 files changed, 0 insertions, 17 deletions
diff --git a/tests/sys_socket_test.cpp b/tests/sys_socket_test.cpp
index 0bde024..38ef68a 100644
--- a/tests/sys_socket_test.cpp
+++ b/tests/sys_socket_test.cpp
@@ -23,13 +23,9 @@
#include <fcntl.h>
#if defined(__BIONIC__)
- #define ACCEPT4_SUPPORTED 1
#define RECVMMSG_SUPPORTED 1
#define SENDMMSG_SUPPORTED 1
#elif defined(__GLIBC_PREREQ)
- #if __GLIBC_PREREQ(2, 9)
- #define ACCEPT4_SUPPORTED 1
- #endif
#if __GLIBC_PREREQ(2, 12)
#define RECVMMSG_SUPPORTED 1
#endif
@@ -38,8 +34,6 @@
#endif
#endif
-#if defined(ACCEPT4_SUPPORTED) || defined(RECVMMSG_SUPPORTED) || defined(SENDMMSG_SUPPORTED)
-
#define SOCK_PATH "test"
static void* ConnectFn(void* data) {
@@ -105,18 +99,12 @@ static void RunTest(void (*test_fn)(struct sockaddr_un*, int),
close(fd);
}
-#endif
TEST(sys_socket, accept4_error) {
-#if defined(ACCEPT4_SUPPORTED)
ASSERT_EQ(-1, accept4(-1, NULL, NULL, 0));
ASSERT_EQ(EBADF, errno);
-#else
- GTEST_LOG_(INFO) << "This test does nothing.\n";
-#endif
}
-#if defined(ACCEPT4_SUPPORTED)
static void TestAccept4(struct sockaddr_un* addr, int fd) {
socklen_t len = sizeof(*addr);
int fd_acc = accept4(fd, reinterpret_cast<struct sockaddr*>(addr), &len, SOCK_CLOEXEC);
@@ -127,14 +115,9 @@ static void TestAccept4(struct sockaddr_un* addr, int fd) {
close(fd_acc);
}
-#endif
TEST(sys_socket, accept4_smoke) {
-#if defined(ACCEPT4_SUPPORTED)
RunTest(TestAccept4, NULL);
-#else
- GTEST_LOG_(INFO) << "This test does nothing.\n";
-#endif
}
#if defined(RECVMMSG_SUPPORTED)