提交 15c7733b 编写于 作者: R Ryan Harper 提交者: Kevin Wolf

Don't reset bs->is_temporary in bdrv_open_common

To fix https://bugs.launchpad.net/qemu/+bug/597402 where qemu fails to
call unlink() on temporary snapshots due to bs->is_temporary getting clobbered
in bdrv_open_common() after being set in bdrv_open() which calls the former.

We don't need to initialize bs->is_temporary in bdrv_open_common().
Signed-off-by: NRyan Harper <ryanh@us.ibm.com>
Signed-off-by: NKevin Wolf <kwolf@redhat.com>
上级 0c6f9c17
......@@ -400,7 +400,6 @@ static int bdrv_open_common(BlockDriverState *bs, const char *filename,
bs->file = NULL;
bs->total_sectors = 0;
bs->is_temporary = 0;
bs->encrypted = 0;
bs->valid_key = 0;
bs->open_flags = flags;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册