diff options
Diffstat (limited to 'net/sched/ematch.c')
-rw-r--r-- | net/sched/ematch.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/sched/ematch.c b/net/sched/ematch.c index 74ff918455a2..d421ec728ee7 100644 --- a/net/sched/ematch.c +++ b/net/sched/ematch.c | |||
@@ -312,10 +312,9 @@ int tcf_em_tree_validate(struct tcf_proto *tp, struct nlattr *nla, | |||
312 | struct tcf_ematch_tree_hdr *tree_hdr; | 312 | struct tcf_ematch_tree_hdr *tree_hdr; |
313 | struct tcf_ematch *em; | 313 | struct tcf_ematch *em; |
314 | 314 | ||
315 | if (!nla) { | 315 | memset(tree, 0, sizeof(*tree)); |
316 | memset(tree, 0, sizeof(*tree)); | 316 | if (!nla) |
317 | return 0; | 317 | return 0; |
318 | } | ||
319 | 318 | ||
320 | err = nla_parse_nested(tb, TCA_EMATCH_TREE_MAX, nla, em_policy); | 319 | err = nla_parse_nested(tb, TCA_EMATCH_TREE_MAX, nla, em_policy); |
321 | if (err < 0) | 320 | if (err < 0) |