test56: fix race condition
Change-Id: Ib8f435f2272fed96e99698ab5030531e733577ca
This commit is contained in:
parent
c1d0e723a3
commit
56be4fa616
1 changed files with 3 additions and 0 deletions
|
@ -3039,6 +3039,9 @@ test_nonblock(void)
|
|||
|
||||
close(server_sd);
|
||||
|
||||
/* Let the socket become writable in the parent process. */
|
||||
sleep(1);
|
||||
|
||||
if (write(client_sd, buf, 1) != 1)
|
||||
test_fail("write() should have succeeded");
|
||||
|
||||
|
|
Loading…
Reference in a new issue