mirror of
https://github.com/xemu-project/xemu.git
synced 2026-07-11 01:24:41 +02:00
xemu-snapshots.c: Check bs_ro refcnt before unref
This commit is contained in:
+1
-1
@@ -169,8 +169,8 @@ static void xemu_snapshots_all_load_data(QEMUSnapshotInfo **info,
|
||||
|
||||
bdrv_flush(bs_ro);
|
||||
bdrv_drain(bs_ro);
|
||||
assert(bs_ro->refcnt == 1);
|
||||
bdrv_unref(bs_ro);
|
||||
assert(bs_ro->refcnt == 0);
|
||||
if (!(*err))
|
||||
xemu_snapshots_dirty = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user