]> err.no Git - linux-2.6/commitdiff
[IP] UDP: Use SEQ_START_TOKEN.
authorYOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Tue, 1 Apr 2008 02:38:15 +0000 (19:38 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 1 Apr 2008 02:38:15 +0000 (19:38 -0700)
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/udp.c

index 7ea1b67b6de1cccbbc5d4332ef45df04578b8aae..1704c1474ea1c622e4c9c4375beea692b12f8072 100644 (file)
@@ -1556,14 +1556,14 @@ static void *udp_seq_start(struct seq_file *seq, loff_t *pos)
        __acquires(udp_hash_lock)
 {
        read_lock(&udp_hash_lock);
-       return *pos ? udp_get_idx(seq, *pos-1) : (void *)1;
+       return *pos ? udp_get_idx(seq, *pos-1) : SEQ_START_TOKEN;
 }
 
 static void *udp_seq_next(struct seq_file *seq, void *v, loff_t *pos)
 {
        struct sock *sk;
 
-       if (v == (void *)1)
+       if (v == SEQ_START_TOKEN)
                sk = udp_get_idx(seq, 0);
        else
                sk = udp_get_next(seq, v);