aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lalancette <clalance@redhat.com>2009-08-05 17:07:35 +0200
committerAnthony Liguori <aliguori@us.ibm.com>2009-08-27 21:23:39 -0500
commita5435be94307d08d143b2b4c2ee68055cd10cf58 (patch)
tree15e4a5b733556102cad6b88a8a3133b6952edb25
parent1ad32e3f44835f9e231d502fdd93a3f627b0b648 (diff)
Fix detached migration with exec.
When trying to do detached migration with exec, I found that the monitor wouldn't always return in a timely manner. I tracked this down to exec_start_outgoing_migration. It appeared we were setting the fd to NONBLOCK'ing, but in point of fact we weren't. This bugfix should also go onto the stable 0.10 branch Signed-off-by: Chris Lalancette <clalance@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
-rw-r--r--migration-exec.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/migration-exec.c b/migration-exec.c
index e3616be5f1..ef4620f79e 100644
--- a/migration-exec.c
+++ b/migration-exec.c
@@ -73,10 +73,7 @@ MigrationState *exec_start_outgoing_migration(const char *command,
goto err_after_open;
}
- if (fcntl(s->fd, F_SETFD, O_NONBLOCK) == -1) {
- dprintf("Unable to set nonblocking mode on file descriptor\n");
- goto err_after_open;
- }
+ socket_set_nonblock(s->fd);
s->opaque = qemu_popen(f, "w");