summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <stephen@networkplumber.org>2022-06-02 14:43:19 -0700
committerStephen Hemminger <stephen@networkplumber.org>2022-06-02 14:43:19 -0700
commit6631e24a1dc4934678195c1aba1b07c9b12726af (patch)
treece92c9f34f052d4aaa729a43329d3604a9c51024
parent6feced7ccdfd99c20ac91530cd04542eada8df57 (diff)
downloadiproute2-6631e24a1dc4934678195c1aba1b07c9b12726af.tar.gz
tc/fw: fix declaration hides parameter
The paramater handle was being redefined as class id. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
-rw-r--r--tc/f_fw.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tc/f_fw.c b/tc/f_fw.c
index 688364f5..3c6ea93d 100644
--- a/tc/f_fw.c
+++ b/tc/f_fw.c
@@ -70,14 +70,14 @@ static int fw_parse_opt(struct filter_util *qu, char *handle, int argc, char **a
while (argc > 0) {
if (matches(*argv, "classid") == 0 ||
matches(*argv, "flowid") == 0) {
- unsigned int handle;
+ unsigned int classid;
NEXT_ARG();
- if (get_tc_classid(&handle, *argv)) {
+ if (get_tc_classid(&classid, *argv)) {
fprintf(stderr, "Illegal \"classid\"\n");
return -1;
}
- addattr_l(n, 4096, TCA_FW_CLASSID, &handle, 4);
+ addattr_l(n, 4096, TCA_FW_CLASSID, &classid, 4);
} else if (matches(*argv, "police") == 0) {
NEXT_ARG();
if (parse_police(&argc, &argv, TCA_FW_POLICE, n)) {