Skip to content

Commit 4d8735b

Browse files
committed
Tests: IOSocket: Check if the file descriptor returned from accept is non-blocking.
1 parent 4ab1c9a commit 4d8735b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tests/io-socket.c

+1
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ task_server_entry (void *data)
5454
/* accept */
5555
cfd = hev_task_io_socket_accept (fd, NULL, NULL, NULL, NULL);
5656
assert (cfd >= 0);
57+
assert ((fcntl (cfd, F_GETFL) & O_NONBLOCK) == O_NONBLOCK);
5758

5859
assert (hev_task_add_fd (task, cfd, POLLIN | POLLOUT) == 0);
5960

0 commit comments

Comments
 (0)