提交 41221378 编写于 作者: M Michal Privoznik

virLeaseReadCustomLeaseFile: Allow server_duid to be NULL

This function is going to be used later in such context where the
argument makes no sense. Teach this function to cope with that
instead of the caller having to deal with passing some dummy
argument.
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
上级 fd9514f8
......@@ -120,7 +120,7 @@ virLeaseReadCustomLeaseFile(virJSONValuePtr leases_array_new,
continue;
}
if (strchr(ip_tmp, ':')) {
if (server_duid && strchr(ip_tmp, ':')) {
/* This is an ipv6 lease */
if ((server_duid_tmp
= virJSONValueObjectGetString(lease_tmp, "server-duid"))) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册