summaryrefslogtreecommitdiffstats
path: root/net/sched/em_text.c
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2008-01-31 11:25:51 +1100
committerPaul Mackerras <paulus@samba.org>2008-01-31 11:25:51 +1100
commitbd45ac0c5daae35e7c71138172e63df5cf644cf6 (patch)
tree5eb5a599bf6a9d7a8a34e802db932aa9e9555de4 /net/sched/em_text.c
parent4eece4ccf997c0e6d8fdad3d842e37b16b8d705f (diff)
parent5bdeae46be6dfe9efa44a548bd622af325f4bdb4 (diff)
Merge branch 'linux-2.6'
Diffstat (limited to 'net/sched/em_text.c')
-rw-r--r--net/sched/em_text.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/net/sched/em_text.c b/net/sched/em_text.c
index d5cd86efb7d..853c5ead87f 100644
--- a/net/sched/em_text.c
+++ b/net/sched/em_text.c
@@ -118,11 +118,14 @@ static int em_text_dump(struct sk_buff *skb, struct tcf_ematch *m)
conf.pattern_len = textsearch_get_pattern_len(tm->config);
conf.pad = 0;
- RTA_PUT_NOHDR(skb, sizeof(conf), &conf);
- RTA_APPEND(skb, conf.pattern_len, textsearch_get_pattern(tm->config));
+ if (nla_put_nohdr(skb, sizeof(conf), &conf) < 0)
+ goto nla_put_failure;
+ if (nla_append(skb, conf.pattern_len,
+ textsearch_get_pattern(tm->config)) < 0)
+ goto nla_put_failure;
return 0;
-rtattr_failure:
+nla_put_failure:
return -1;
}