oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock()

The fcntl(fd, F_SETFL, O_NONBLOCK) flag is not specific to sockets.
Rename to qemu_set_nonblock() just like qemu_set_cloexec().

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
This commit is contained in:
Stefan Hajnoczi 2013-03-27 10:10:43 +01:00 committed by Luiz Capitulino
parent 5d45de9796
commit f9e8cacc55
14 changed files with 27 additions and 27 deletions

View file

@ -134,14 +134,14 @@ void qemu_vfree(void *ptr)
free(ptr);
}
void socket_set_block(int fd)
void qemu_set_block(int fd)
{
int f;
f = fcntl(fd, F_GETFL);
fcntl(fd, F_SETFL, f & ~O_NONBLOCK);
}
void socket_set_nonblock(int fd)
void qemu_set_nonblock(int fd)
{
int f;
f = fcntl(fd, F_GETFL);