'datalen' is unsigned, use 'ret' instead to catch a negative return value.
Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
---
diff --git a/net/sched/act_simple.c b/net/sched/act_simple.c
index fbde461..b78d015 100644
--- a/net/sched/act_simple.c
+++ b/net/sched/act_simple.c
@@ -114,9 +114,10 @@ static int tcf_simp_init(struct nlattr *nla, struct nlattr *est,
if (defdata == NULL)
return -EINVAL;
- datalen = nla_len(tb[TCA_DEF_DATA]);
- if (datalen <= 0)
+ ret = nla_len(tb[TCA_DEF_DATA]);
+ if (ret <= 0)
return -EINVAL;
+ datalen = ret;
pc = tcf_hash_check(parm->index, a, bind, &simp_hash_info);
if (!pc) {
--
| David Miller | [GIT]: Networking |
| Andi Kleen | Please pull ACPI updates |
| Greg Kroah-Hartman | [PATCH 002/196] Chinese: rephrase English introduction in HOWTO |
| Fred . | Please add ZFS support (from GPL sources) |
git: | |
| Theodore Ts'o | Any objectsions to enhancing git-log to show tags/branch heads? |
| Alex R.M. Turner | Re: Problem with a push |
| Sebastian Schuberth | git on Cygwin: Not a valid object name HEAD |
| Dan Farina | backup or mirror a repository |
| Theo de Raadt | That whole "Linux stealing our code" thing |
| Jeff Ross | U320 Drive on U160 controller? |
| Richard Stallman | Real men don't attack straw men |
| Bertram Scharpf | First install: Grub doesn't find partitions |
| Jim Winstead Jr. | Re: Root Disk/Book Disk Compatibility |
| Desmond A. Kirkpatrick | ATI GUP bug with Linux 'tickler' |
| erc | HARDWARE COMPATIBILITY LIST |
| L.G. Ted Stern | Psfrag.sty in TeX, ext2fs |
