Skip to content

Commit

Permalink
cls_flow: remove one dynamic array
Browse files Browse the repository at this point in the history
Its better to use a predefined size for this small automatic variable.

Removes a sparse error as well :

net/sched/cls_flow.c:288:13: error: bad constant expression

Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
Eric Dumazet authored and davem330 committed Dec 14, 2011
1 parent fcdf95c commit 3a53943
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/sched/cls_flow.c
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ static int flow_classify(struct sk_buff *skb, const struct tcf_proto *tp,
int r;

list_for_each_entry(f, &head->filters, list) {
u32 keys[f->nkeys];
u32 keys[FLOW_KEY_MAX + 1];
struct flow_keys flow_keys;

if (!tcf_em_tree_match(skb, &f->ematches, NULL))
Expand Down

0 comments on commit 3a53943

Please sign in to comment.