Skip to content

Commit

Permalink
[PKT_SCHED] ematch: Fix build warning.
Browse files Browse the repository at this point in the history
Commit 954415e ("[PKT_SCHED] ematch:
tcf_em_destroy robustness") removed a cast on em->data when
passing it to kfree(), but em->data is an integer type that can
hold pointers as well as other values so the cast is necessary.

Signed-off-by: David S. Miller <[email protected]>
davem330 committed Feb 10, 2008
1 parent 25f6663 commit 30ddb15
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/sched/ematch.c
Original file line number Diff line number Diff line change
@@ -410,7 +410,7 @@ void tcf_em_tree_destroy(struct tcf_proto *tp, struct tcf_ematch_tree *tree)
if (em->ops->destroy)
em->ops->destroy(tp, em);
else if (!tcf_em_is_simple(em))
kfree(em->data);
kfree((void *) em->data);
module_put(em->ops->owner);
}
}

0 comments on commit 30ddb15

Please sign in to comment.