提交 83b70f74 编写于 作者: J Jiri Denemark 提交者: Eric Blake

netlink: Fix build with libnl-3

Commit 64297313 added three direct
references to nl_handle_* instead of using our aliases which hide
differences between libnl-3 and libnl-1.
(cherry picked from commit d9d39e62)
上级 32aeec7b
......@@ -98,7 +98,7 @@ static int nextWatch = 1;
# define NETLINK_EVENT_ALLOC_EXTENT 10
static virNetlinkEventSrvPrivatePtr server = NULL;
static struct nl_handle *placeholder_nlhandle = NULL;
static virNetlinkHandle *placeholder_nlhandle = NULL;
/* Function definitions */
......@@ -130,7 +130,7 @@ virNetlinkStartup(void)
{
if (placeholder_nlhandle)
return 0;
placeholder_nlhandle = nl_handle_alloc();
placeholder_nlhandle = virNetlinkAlloc();
if (!placeholder_nlhandle) {
virReportSystemError(errno, "%s",
_("cannot allocate placeholder nlhandle for netlink"));
......@@ -149,7 +149,7 @@ void
virNetlinkShutdown(void)
{
if (placeholder_nlhandle) {
nl_handle_destroy(placeholder_nlhandle);
virNetlinkFree(placeholder_nlhandle);
placeholder_nlhandle = NULL;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册