qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] Fix brown-paper-bag bugs from live-migration patch


From: Charles Duffy
Subject: [Qemu-devel] [PATCH] Fix brown-paper-bag bugs from live-migration patch
Date: Wed, 12 Nov 2008 15:34:39 -0600
User-agent: Thunderbird 2.0.0.17 (X11/20080925)

In TCP migration, prevent an endless loop trying to retrieve error status. In exec migration, set the close pointer in the FdMigrationState structure.

Color me embarrassed.

Signed-off-by: Charles Duffy <address@hidden>
diff --git a/migration-exec.c b/migration-exec.c
index 5d0b215..caeed4b 100644
--- a/migration-exec.c
+++ b/migration-exec.c
@@ -85,6 +85,7 @@ MigrationState *exec_start_outgoing_migration(const char 
*command,
 
     s->opaque = qemu_popen(f, "w");
 
+    s->close = exec_close;
     s->get_error = file_errno;
     s->write = file_write;
     s->mig_state.cancel = migrate_fd_cancel;
diff --git a/migration-tcp.c b/migration-tcp.c
index 100644b..6fc1943 100644
--- a/migration-tcp.c
+++ b/migration-tcp.c
@@ -32,7 +32,7 @@
 
 static int socket_errno(FdMigrationState *s)
 {
-    return (s->get_error(s));
+    return socket_error();
 }
 
 static int socket_write(FdMigrationState *s, const void * buf, size_t size)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]