提交 3d124636 编写于 作者: O Osier Yang 提交者: Cole Robinson

virsh: Fix segfault of snapshot-list

'snaps' is used after free()'ed.
(cherry picked from commit e0ad4669)
上级 6bae2c41
......@@ -866,7 +866,7 @@ vshSnapshotListCollect(vshControl *ctl, virDomainPtr dom,
goto cleanup;
}
if (from) {
snaps[snaplist->nsnaps++] = from;
snaplist->snaps[snaplist->nsnaps++].snap = from;
virDomainSnapshotRef(from);
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册