diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2018-10-06 13:55:19 +0900 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2018-10-10 14:43:05 +0900 |
commit | 1046bf9b1a484a086f61f646c0cacc84b571b4e1 (patch) | |
tree | efb2752e5fb56c1e2f2fd7579d38bf232d0e10f1 /src/network/networkd-brvlan.c | |
parent | 0d0f02cd15fcb7fed2d2b1089fe64641f8b71134 (diff) | |
download | systemd-1046bf9b1a484a086f61f646c0cacc84b571b4e1.tar.gz systemd-1046bf9b1a484a086f61f646c0cacc84b571b4e1.tar.bz2 systemd-1046bf9b1a484a086f61f646c0cacc84b571b4e1.zip |
network: add destroy callbacks for asynchronous netlink calls
Diffstat (limited to 'src/network/networkd-brvlan.c')
-rw-r--r-- | src/network/networkd-brvlan.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/network/networkd-brvlan.c b/src/network/networkd-brvlan.c index fe418b4768..3707347a68 100644 --- a/src/network/networkd-brvlan.c +++ b/src/network/networkd-brvlan.c @@ -195,10 +195,13 @@ int br_vlan_configure(Link *link, uint16_t pvid, uint32_t *br_vid_bitmap, uint32 return log_link_error_errno(link, r, "Could not close IFLA_AF_SPEC container: %m"); /* send message to the kernel */ - r = sd_netlink_call_async(rtnl, req, set_brvlan_handler, NULL, link, 0, NULL); + r = sd_netlink_call_async(rtnl, req, set_brvlan_handler, + link_netlink_destroy_callback, link, 0, NULL); if (r < 0) return log_link_error_errno(link, r, "Could not send rtnetlink message: %m"); + link_ref(link); + return 0; } |