Write table offset and size in one syscall (Gleb Natapov)
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>
Tue, 2 Dec 2008 20:10:14 +0000 (20:10 +0000)
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>
Tue, 2 Dec 2008 20:10:14 +0000 (20:10 +0000)
commit643e5399bbb1dd6113e787c4d86c942a3a7c76ca
treeb2f647bf1481647e0d2cebef8b9e6238a74b831c
parenta32ef786f4556ebb5e4b7329ac80810ebaa58a81
Write table offset and size in one syscall (Gleb Natapov)

Otherwise if VM is killed between two writes data may be lost.
But if offset and size fields are at the same disk block one
write should update them both simultaneously.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5859 c046a42c-6fe2-441c-8c8c-71466251a162
block-qcow2.c