1 Star 0 Fork 71

梓瑶/libvirt

forked from src-openEuler/libvirt 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
virshCheckpointListCollect-Do-not-pass-NULL-to-qsort.patch 1.01 KB
一键复制 编辑 原始数据 按行查看 历史
From f64a491232e5aeca4d0d86523564bdea9913bb73 Mon Sep 17 00:00:00 2001
From: Tim Wiederhake <twiederh@redhat.com>
Date: Mon, 19 Apr 2021 13:54:15 +0200
Subject: [PATCH 063/108] virshCheckpointListCollect: Do not pass NULL to qsort
Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Laine Stump <laine@redhat.com>
(cherry picked from commit 1c34211c22de28127a509edbf2cf2f44cb0d891e)
---
tools/virsh-checkpoint.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/virsh-checkpoint.c b/tools/virsh-checkpoint.c
index 1a3a74b2d5..6effbdc26c 100644
--- a/tools/virsh-checkpoint.c
+++ b/tools/virsh-checkpoint.c
@@ -622,7 +622,8 @@ virshCheckpointListCollect(vshControl *ctl,
}
}
- if (!(orig_flags & VIR_DOMAIN_CHECKPOINT_LIST_TOPOLOGICAL))
+ if (!(orig_flags & VIR_DOMAIN_CHECKPOINT_LIST_TOPOLOGICAL) &&
+ checkpointlist->chks)
qsort(checkpointlist->chks, checkpointlist->nchks,
sizeof(*checkpointlist->chks), virshChkSorter);
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/ziyao233/libvirt.git
git@gitee.com:ziyao233/libvirt.git
ziyao233
libvirt
libvirt
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385