From a2b413512443e67cd58285b8d98b84792a66c710 Mon Sep 17 00:00:00 2001 From: Juan Quintela Date: Tue, 4 Sep 2012 12:45:42 +0200 Subject: savevm: make qemu_file_put_notify() return errors Signed-off-by: Juan Quintela Reviewed-by: Paolo Bonzini --- migration.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'migration.c') diff --git a/migration.c b/migration.c index 2c93951423..62e030487d 100644 --- a/migration.c +++ b/migration.c @@ -287,10 +287,11 @@ static void migrate_fd_completed(MigrationState *s) static void migrate_fd_put_notify(void *opaque) { MigrationState *s = opaque; + int ret; qemu_set_fd_handler2(s->fd, NULL, NULL, NULL, NULL); - qemu_file_put_notify(s->file); - if (s->file && qemu_file_get_error(s->file)) { + ret = qemu_file_put_notify(s->file); + if (ret) { migrate_fd_error(s); } } -- cgit v1.2.3-55-g7522