summaryrefslogtreecommitdiffstats
path: root/tc/m_nat.c
diff options
context:
space:
mode:
Diffstat (limited to 'tc/m_nat.c')
-rw-r--r--tc/m_nat.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/tc/m_nat.c b/tc/m_nat.c
index f5de4d4c..1bb6495b 100644
--- a/tc/m_nat.c
+++ b/tc/m_nat.c
@@ -129,10 +129,9 @@ parse_nat(struct action_util *a, int *argc_p, char ***argv_p, int tca_id, struct
}
}
- tail = NLMSG_TAIL(n);
- addattr_l(n, MAX_MSG, tca_id, NULL, 0);
+ tail = addattr_nest(n, MAX_MSG, tca_id);
addattr_l(n, MAX_MSG, TCA_NAT_PARMS, &sel, sizeof(sel));
- tail->rta_len = (char *)NLMSG_TAIL(n) - (char *)tail;
+ addattr_nest_end(n, tail);
*argc_p = argc;
*argv_p = argv;