From: Stephen Hemminger <redacted>
Date: Mon, 11 Feb 2008 17:12:50 -0800
To: David S. Miller <davem@davemloft.net>
When a user's name has "special" characters such as a "." as mine
does, it must be surrounded by double-quotes or else it is a syntax
error by SMTP rules. For this reason your patch postings were
rejected by vger.kernel.org
This fixes possible problems when trie_firstleaf() returns NULL
to trie_leafindex().
Signed-off-by: Stephen Hemminger <redacted>
Applied, thanks Stephen.
quoted hunk
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c
index f5fba3f..2d89527 100644
--- a/net/ipv4/fib_trie.c
+++ b/net/ipv4/fib_trie.c
@@ -1762,11 +1762,9 @@ static struct leaf *trie_leafindex(struct trie *t, int index)
{
struct leaf *l = trie_firstleaf(t);
- while (index-- > 0) {
+ while (l && index-- > 0)
l = trie_nextleaf(l);
- if (!l)
- break;
- }
+
return l;
}
--
1.5.3.8