mirror of
https://github.com/torvalds/linux.git
synced 2024-11-23 04:31:50 +00:00
ppp: Remove redundant BUG_ON() check in ppp_pernet
Passing NULL to ppp_pernet causes a crash via BUG_ON. Dereferencing net in net_generic() also has the same effect. This patch removes the redundant BUG_ON check on the same parameter. Signed-off-by: Xu Wang <vulab@iscas.ac.cn> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
36a78867f8
commit
8a3f44a0bb
@ -296,8 +296,6 @@ static struct class *ppp_class;
|
||||
/* per net-namespace data */
|
||||
static inline struct ppp_net *ppp_pernet(struct net *net)
|
||||
{
|
||||
BUG_ON(!net);
|
||||
|
||||
return net_generic(net, ppp_net_id);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user