Skip to content
Snippets Groups Projects
user avatar
Gonglei (Arei) authored
Technically, fcntl(soc, F_SETFL, O_NONBLOCK)
is incorrect since it clobbers all other file flags.
We can use F_GETFL to get the current flags, set or
clear the O_NONBLOCK flag, then use F_SETFL to set the flags.

Using the qemu_set_nonblock() wrapper.

Signed-off-by: default avatarGonglei <arei.gonglei@huawei.com>
Signed-off-by: default avatarWangxin <wangxinxin.wang@huawei.com>
Reviewed-by: default avatarEric Blake <eblake@redhat.com>
Signed-off-by: default avatarStefan Hajnoczi <stefanha@redhat.com>
16b38080
History
Name Last commit Last update
..