Push kernel lock down to rt_setsource() to make `ifa' dereference safe.
authormvs <mvs@openbsd.org>
Fri, 26 Mar 2021 22:40:08 +0000 (22:40 +0000)
committermvs <mvs@openbsd.org>
Fri, 26 Mar 2021 22:40:08 +0000 (22:40 +0000)
commit6ea313b170319aed9e423222b5dfacede227785c
treed795018a99ed569fa0040a9f247d0239972bb7e3
parent48eb9341f2a2c6b9c06913ea1a3b5489212973d6
Push kernel lock down to rt_setsource() to make `ifa' dereference safe.
Netlock doesn't make sense here because ifa_ifwithaddr() holds kernel
lock while performs lists walkthrough.

This was made to decrease the future diff for PF_ROUTE sockets
unlocking. This time kernel lock is still held while we perform
rt_setsource().

ok mpi@
sys/net/rtsock.c