netlink: Automatically request ACKs when a callback function is given
PATCH 1/1 netlink: Automatically request ACKs when a callback function is given
Supplying a callback function without setting NLM_F_ACK results in no ACKs to be sent by the kernel and thus the callback will never be called.
--- ell/netlink.c | 3 +++ 1 file changed, 3 insertions(+)
ell/netlink.c +3 -0
@@ -399,6 +399,9 @@ LIB_EXPORT unsigned int l_netlink_send(struct l_netlink *netlink,if (flags &0xff )return 0 ; +if (function) + flags |=NLM_F_ACK ; + size =NLMSG_ALIGN (sizeof (struct command )) +NLMSG_HDRLEN +NLMSG_ALIGN (len);
Signature · 1 line
1.9.1
Hi Patrik,
Quoted 5 lines
Supplying a callback function without setting
NLM_F_ACKresults in no ACKs to be sent by the kernel and thus the callback will never be called.
---ell/netlink.c| 3 +++1 file changed, 3 insertions(+)
patch has been applied.
Regards
Marcel