Re: [Qemu-devel] [PATCH v3] qemu_file: use fwrite() correctly

2014-02-18 Thread Eric Blake
On 02/18/2014 08:56 AM, Juan Quintela wrote: > fwrite() returns the number of items written. But when there is one > error, it can return a short write. > > In the particular bug that I was tracking, I did a migration to a > read-only filesystem. And it was able to finish the migration > correct

[Qemu-devel] [PATCH v3] qemu_file: use fwrite() correctly

2014-02-18 Thread Juan Quintela
fwrite() returns the number of items written. But when there is one error, it can return a short write. In the particular bug that I was tracking, I did a migration to a read-only filesystem. And it was able to finish the migration correctly. fwrite() never returned a negative error code, nor z