qcow2: Fix bdrv_write_compressed error handling
If during allocation of compressed clusters the cluster was already allocated uncompressed, fail and properly release the l2_table (the latter avoids a failed assertion). While at it, make it return some real error numbers instead of -1. Signed-off-by: NKevin Wolf <kwolf@redhat.com> Reviewed-by: NDong Xu Wang <wdongxu@linux.vnet.ibm.com>
Showing
想要评论请 注册 或 登录