From: David Miller Date: Wed, 27 Sep 2006 23:25:17 +0000 (-0700) Subject: PKT_SCHED: cls_basic: Use unsigned int when generating handle X-Git-Tag: v2.6.17.14~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a7f0f4dc1aa3b640549507ed1ebfb46ab45eebfe;p=thirdparty%2Fkernel%2Fstable.git PKT_SCHED: cls_basic: Use unsigned int when generating handle Prevents filters from being added if the first generated handle already exists. Signed-off-by: Kim Nordlund Signed-off-by: Thomas Graf Signed-off-by: Greg Kroah-Hartman --- diff --git a/net/sched/cls_basic.c b/net/sched/cls_basic.c index dfb300bb6baa0..0f425448fdf6e 100644 --- a/net/sched/cls_basic.c +++ b/net/sched/cls_basic.c @@ -197,7 +197,7 @@ static int basic_change(struct tcf_proto *tp, unsigned long base, u32 handle, if (handle) f->handle = handle; else { - int i = 0x80000000; + unsigned int i = 0x80000000; do { if (++head->hgenerator == 0x7FFFFFFF) head->hgenerator = 1;