]> git.baikalelectronics.ru Git - kernel.git/commit
ipv6: exthdrs: use swap() instead of open coding it
authorGuo Zhengkui <guozhengkui@vivo.com>
Tue, 12 Apr 2022 03:20:58 +0000 (11:20 +0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 13 Apr 2022 11:20:58 +0000 (12:20 +0100)
commit7969cbd3c18bbe265ed0d8abd0eb1df323226c67
tree45125dffe14635b658b8abf940ca1a99a02d5e0b
parentcde029b185d45356bc49b8ae56f83fcbcfcdb0f0
ipv6: exthdrs: use swap() instead of open coding it

Address the following coccicheck warning:
net/ipv6/exthdrs.c:620:44-45: WARNING opportunity for swap()

by using swap() for the swapping of variable values and drop
the tmp (`addr`) variable that is not needed any more.

Signed-off-by: Guo Zhengkui <guozhengkui@vivo.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/exthdrs.c