lkml.org 
[lkml]   [2005]   [Nov]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH]IPv6: small fix for ipv6_dev_get_saddr(...)
From
In article <43786A16.9070100@21cn.com> (at Mon, 14 Nov 2005 18:42:30 +0800), Yan Zheng <yanzheng@21cn.com> says:

> The "score.rule++" doesn't make any sense for me.
> According to codes above, I think it should be "hiscore.rule++;" .

Oops, you're right.

> Signed-off-by: Yan Zheng<yanzheng@21cn.com>
Acked-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>

> /* Rule 8: Use longest matching prefix */
> - if (hiscore.rule < 8)
> + if (hiscore.rule < 8) {
> hiscore.matchlen = ipv6_addr_diff(&ifa_result->addr, daddr);
> - score.rule++;
> + hiscore.rule++;
> + }
> score.matchlen = ipv6_addr_diff(&ifa->addr, daddr);
> if (score.matchlen > hiscore.matchlen) {
> score.rule = 8;
>

--
YOSHIFUJI Hideaki @ USAGI Project <yoshfuji@linux-ipv6.org>
GPG-FP : 9022 65EB 1ECF 3AD1 0BDF 80D8 4807 F894 E062 0EEA
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-11-15 02:24    [W:0.098 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site