]> git.proxmox.com Git - mirror_iproute2.git/blobdiff - tc/f_fw.c
man: tc-taprio.8: fix syntax error
[mirror_iproute2.git] / tc / f_fw.c
index c39789b345f4b5c9a2b577d68d2e459eb747fda7..adce2bdb7d8af353133af9a852b0494e2dd36e15 100644 (file)
--- a/tc/f_fw.c
+++ b/tc/f_fw.c
@@ -13,7 +13,6 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
-#include <syslog.h>
 #include <fcntl.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
@@ -68,8 +67,7 @@ static int fw_parse_opt(struct filter_util *qu, char *handle, int argc, char **a
        if (argc == 0)
                return 0;
 
-       tail = NLMSG_TAIL(n);
-       addattr_l(n, 4096, TCA_OPTIONS, NULL, 0);
+       tail = addattr_nest(n, 4096, TCA_OPTIONS);
 
        if (mask_set)
                addattr32(n, MAX_MSG, TCA_FW_MASK, mask);
@@ -120,7 +118,7 @@ static int fw_parse_opt(struct filter_util *qu, char *handle, int argc, char **a
                }
                argc--; argv++;
        }
-       tail->rta_len = (void *) NLMSG_TAIL(n) - (void *) tail;
+       addattr_nest_end(n, tail);
        return 0;
 }