network: cancel netlink calls for detached requests
Store the asynchronous netlink slot in the Request object and release it
when the request is detached. This cancels the pending callback instead of
keeping the request alive until its reply arrives.
Follow-up for 80d62d4f1a
This commit is contained in:
@@ -80,6 +80,7 @@ typedef struct Request {
|
||||
* request, and pass this request to the netlink_call_async(), and set the destroy function
|
||||
* to the slot. */
|
||||
request_netlink_handler_t netlink_handler;
|
||||
sd_netlink_slot *netlink_slot;
|
||||
|
||||
bool waiting_reply;
|
||||
} Request;
|
||||
|
||||
Reference in New Issue
Block a user