Signed-off-by: Tim Wiederhake <twiederh@xxxxxxxxxx> --- 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 afe849dd16..e88f9ffb47 100644 --- a/tools/virsh-checkpoint.c +++ b/tools/virsh-checkpoint.c @@ -628,7 +628,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.26.3