mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-15 05:11:32 +00:00
[IP] UDP: Use SEQ_START_TOKEN.
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
5e0751f57a
commit
b50660f1fe
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user