qcow2: Check new refcount table size on growth
commit2b5d5953eec0cc541857c3df812bdf8421596ab2
authorKevin Wolf <kwolf@redhat.com>
Wed, 26 Mar 2014 12:05:50 +0000 (26 13:05 +0100)
committerStefan Hajnoczi <stefanha@redhat.com>
Tue, 1 Apr 2014 13:22:34 +0000 (1 15:22 +0200)
tree46005cfd30454c30b3e4853a8146e1ac260bee3c
parentdb8a31d11d6a60f48d6817530640d75aa72a9a2f
qcow2: Check new refcount table size on growth

If the size becomes larger than what qcow2_open() would accept, fail the
growing operation.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
block/qcow2-refcount.c
block/qcow2.c
block/qcow2.h