Paolo Bonzini <pbonz...@redhat.com> wrote: > Second, drop the file descriptor indirection, and write directly to the > QEMUFile. > > Signed-off-by: Paolo Bonzini <pbonz...@redhat.com>
> + qemu_put_buffer(s->migration_file, buf, size); > + if (qemu_file_get_error(s->migration_file)) { > + return qemu_file_get_error(s->migration_file); Rest of patch is really, really nice. But here, please, use a local variable. qemu_put_buffer(s->migration_file, buf, size); ret = qemu_file_get_error(s->migration_file); if (ret) { return ret; }