diff options
Diffstat (limited to 'tests-m32/net-yy-unix.c')
-rw-r--r-- | tests-m32/net-yy-unix.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/tests-m32/net-yy-unix.c b/tests-m32/net-yy-unix.c index 21822db9..40ac3a63 100644 --- a/tests-m32/net-yy-unix.c +++ b/tests-m32/net-yy-unix.c @@ -2,6 +2,7 @@ * This file is part of net-yy-unix strace test. * * Copyright (c) 2013-2017 Dmitry V. Levin <ldv@altlinux.org> + * Copyright (c) 2016-2018 The strace developers. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -34,10 +35,11 @@ #include <stdlib.h> #include <string.h> #include <unistd.h> -#include <sys/param.h> #include <sys/socket.h> #include <sys/un.h> +#include "accept_compat.h" + #define TEST_SOCKET "net-yy-unix.socket" int @@ -107,7 +109,7 @@ main(void) struct sockaddr * const accept_sa = tail_alloc(sizeof(addr)); memset(accept_sa, 0, sizeof(addr)); *len = sizeof(addr); - int accept_fd = accept(listen_fd, accept_sa, len); + int accept_fd = do_accept(listen_fd, accept_sa, len); if (accept_fd < 0) perror_msg_and_fail("accept"); unsigned long accept_inode = inode_of_sockfd(accept_fd); @@ -180,7 +182,7 @@ main(void) memset(accept_sa, 0, sizeof(addr)); *len = sizeof(addr); - accept_fd = accept(listen_fd, accept_sa, len); + accept_fd = do_accept(listen_fd, accept_sa, len); if (accept_fd < 0) perror_msg_and_fail("accept"); accept_inode = inode_of_sockfd(accept_fd); |