summaryrefslogtreecommitdiffstats
path: root/src/msg.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/msg.c')
-rw-r--r--src/msg.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/msg.c b/src/msg.c
index 02f812b..0824eb3 100644
--- a/src/msg.c
+++ b/src/msg.c
@@ -164,6 +164,13 @@ struct nlmsghdr *mnl_nlmsg_next(const struct nlmsghdr *nlh, int *len)
return (struct nlmsghdr *)((void *)nlh + mnl_align(nlh->nlmsg_len));
}
+/**
+ * mnl_nlmsg_get_tail - get the ending of the netlink message
+ * @nlh: pointer to netlink message
+ *
+ * This function returns a pointer to the netlink message tail. This is useful
+ * to build a message since we continue adding attribute at the end of it.
+ */
void *mnl_nlmsg_get_tail(const struct nlmsghdr *nlh)
{
return (struct nlmsghdr *)((void *)nlh + mnl_align(nlh->nlmsg_len));