On Fri, Aug 26, 2011 at 9:48 PM, Paolo Bonzini <pbonz...@redhat.com> wrote: > On 08/26/2011 01:25 PM, Daniel P. Berrange wrote: >> >> diff --git a/migration.c b/migration.c >> index f5959b4..6448d0b 100644 >> --- a/migration.c >> +++ b/migration.c >> @@ -319,6 +319,11 @@ ssize_t migrate_fd_put_buffer(void *opaque, const >> void *data, size_t size) >> FdMigrationState *s = opaque; >> ssize_t ret; >> >> + if (s->state == MIG_STATE_ERROR || >> + s->state == MIG_STATE_CANCELLED) { >> + return -EIO; >> + } >> + >> do { >> ret = s->write(s, data, size); >> } while (ret == -1&& ((s->get_error(s)) == EINTR)); >> >> >> >> I think I slightly prefer this second option, since it avoids the EBADF >> scenario. Other opinions ? > > > I agree.
Hello Paolo, berrange, What's the status of this patch? Gren also touched this problem (failed to migrate_cancel). Old thread: http://lists.nongnu.org/archive/html/qemu-devel/2011-08/msg03245.html Amos.