Commit 1a751ebf authored by Stefan Hajnoczi's avatar Stefan Hajnoczi Committed by Luiz Capitulino

qemu-socket: set passed fd non-blocking in socket_connect()

socket_connect() sets non-blocking on TCP or UNIX domain sockets if a
callback function is passed.  Do the same for file descriptor passing,
otherwise we could unexpectedly be using a blocking file descriptor.
Signed-off-by: default avatarStefan Hajnoczi <>
Reviewed-by: default avatarEric Blake <>
Signed-off-by: default avatarLuiz Capitulino <>
parent fc13fa00
......@@ -910,6 +910,7 @@ int socket_connect(SocketAddress *addr, Error **errp,
fd = monitor_get_fd(cur_mon, addr->fd->str, errp);
if (callback) {
callback(fd, opaque);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment