mirror of
https://sourceware.org/git/glibc.git
synced 2025-01-11 20:00:07 +00:00
tst-cancel4: Make blocking on write more portable
* nptl/tst-cancel4.c (tf_send, tf_sendto): Set socket buffer size after connecting.
This commit is contained in:
parent
4ebd73d43f
commit
b71bc845dd
@ -753,13 +753,13 @@ tf_send (void *arg)
|
||||
if (tempfd2 == -1)
|
||||
FAIL_EXIT1 ("socket (AF_UNIX, SOCK_STREAM, 0): %m");
|
||||
|
||||
set_socket_buffer (tempfd2);
|
||||
|
||||
if (connect (tempfd2, (struct sockaddr *) &sun, sizeof (sun)) != 0)
|
||||
FAIL_EXIT1 ("connect: %m");
|
||||
|
||||
unlink (sun.sun_path);
|
||||
|
||||
set_socket_buffer (tempfd2);
|
||||
|
||||
xpthread_barrier_wait (&b2);
|
||||
|
||||
if (arg != NULL)
|
||||
@ -1288,13 +1288,13 @@ tf_sendto (void *arg)
|
||||
if (tempfd2 == -1)
|
||||
FAIL_EXIT1 ("socket (AF_UNIX, SOCK_STREAM, 0): %m");
|
||||
|
||||
set_socket_buffer (tempfd2);
|
||||
|
||||
if (connect (tempfd2, (struct sockaddr *) &sun, sizeof (sun)) != 0)
|
||||
FAIL_EXIT1 ("connect: %m");
|
||||
|
||||
unlink (sun.sun_path);
|
||||
|
||||
set_socket_buffer (tempfd2);
|
||||
|
||||
xpthread_barrier_wait (&b2);
|
||||
|
||||
if (arg != NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user