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

nss: Don't leak @ipAddr

In aiforaf() (which exists only when building for BSD) the
@ipAddr may be leaked.
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
上级 ffdce9b1
......@@ -643,6 +643,7 @@ aiforaf(const char *name, int af, struct addrinfo *pai, struct addrinfo **aip)
hints.ai_family = af;
if (getaddrinfo(ipAddr, NULL, &hints, &res0)) {
VIR_FREE(ipAaddr);
addrList++;
continue;
}
......@@ -654,6 +655,7 @@ aiforaf(const char *name, int af, struct addrinfo *pai, struct addrinfo **aip)
while ((*aip)->ai_next)
*aip = (*aip)->ai_next;
VIR_FREE(ipAaddr);
addrList++;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册