Re: [Qemu-devel] [PATCH 4/4] migration: simplify writev vs. non-writev logic

2013-04-09 Thread Juan Quintela
Paolo Bonzini pbonz...@redhat.com wrote: Check f-iovcnt in add_to_iovec, f-buf_index in qemu_put_buffer/byte. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- savevm.c | 22 +- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/savevm.c b/savevm.c index

Re: [Qemu-devel] [PATCH 4/4] migration: simplify writev vs. non-writev logic

2013-04-09 Thread Paolo Bonzini
Il 09/04/2013 13:43, Juan Quintela ha scritto: @@ -687,12 +685,10 @@ void qemu_put_byte(QEMUFile *f, int v) f-bytes_xfer++; if (f-ops-writev_buffer) { add_to_iovec(f, f-buf + f-buf_index, 1); -f-buf_index++; -} else { -f-buf_index++; -

Re: [Qemu-devel] [PATCH 4/4] migration: simplify writev vs. non-writev logic

2013-04-09 Thread Juan Quintela
Paolo Bonzini pbonz...@redhat.com wrote: Il 09/04/2013 13:43, Juan Quintela ha scritto: @@ -687,12 +685,10 @@ void qemu_put_byte(QEMUFile *f, int v) f-bytes_xfer++; if (f-ops-writev_buffer) { add_to_iovec(f, f-buf + f-buf_index, 1); -f-buf_index++; -}

Re: [Qemu-devel] [PATCH 4/4] migration: simplify writev vs. non-writev logic

2013-04-09 Thread Orit Wasserman
On 04/09/2013 02:53 PM, Paolo Bonzini wrote: Il 09/04/2013 13:43, Juan Quintela ha scritto: @@ -687,12 +685,10 @@ void qemu_put_byte(QEMUFile *f, int v) f-bytes_xfer++; if (f-ops-writev_buffer) { add_to_iovec(f, f-buf + f-buf_index, 1); -f-buf_index++; -} else