Re: [Qemu-devel] [PATCH 1/10] Refactor QEMUFile for live migration

2008-09-12 Thread Blue Swirl
On 9/9/08, Anthony Liguori [EMAIL PROTECTED] wrote: To support live migration, we override QEMUFile so that instead of writing to disk, the save/restore state happens over a network connection. This patch makes QEMUFile read/write operations function pointers so that we can override them

Re: [Qemu-devel] [PATCH 1/10] Refactor QEMUFile for live migration

2008-09-10 Thread Chris Lalancette
Anthony Liguori wrote: snip void qemu_fflush(QEMUFile *f) { -if (!f-is_writable) +if (!f-put_buffer) return; + if (f-buf_index 0) { -if (f-is_file) { -fseek(f-outfile, f-buf_offset, SEEK_SET); -fwrite(f-buf, 1, f-buf_index,