Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ipv4: netfilter: use PTR_RET instead of IS_ERR + PTR_ERR

This uses PTR_RET instead of IS_ERR and PTR_ERR in order to increase
readability.

Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>

authored by

Silviu-Mihai Popescu and committed by
Pablo Neira Ayuso
015ba03c 2d2fd8c5

+1 -3
+1 -3
net/ipv4/netfilter/arptable_filter.c
··· 48 48 net->ipv4.arptable_filter = 49 49 arpt_register_table(net, &packet_filter, repl); 50 50 kfree(repl); 51 - if (IS_ERR(net->ipv4.arptable_filter)) 52 - return PTR_ERR(net->ipv4.arptable_filter); 53 - return 0; 51 + return PTR_RET(net->ipv4.arptable_filter); 54 52 } 55 53 56 54 static void __net_exit arptable_filter_net_exit(struct net *net)