diff options
Diffstat (limited to 'net/core/dev_mcast.c')
-rw-r--r-- | net/core/dev_mcast.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/core/dev_mcast.c b/net/core/dev_mcast.c index 1c4f6198459..896b0ca5aed 100644 --- a/net/core/dev_mcast.c +++ b/net/core/dev_mcast.c @@ -246,7 +246,11 @@ static int dev_mc_seq_open(struct inode *inode, struct file *file) res = seq_open(file, &dev_mc_seq_ops); if (!res) { seq = file->private_data; - seq->private = get_net(PROC_NET(inode)); + seq->private = get_proc_net(inode); + if (!seq->private) { + seq_release(inode, file); + res = -ENXIO; + } } return res; } |