router: close socket upon NETEV_IFINDEX_CHANGE
authorKoen Aerts <aertskoen5@gmail.com>
Tue, 13 Aug 2019 13:02:19 +0000 (15:02 +0200)
committerHans Dedecker <dedeckeh@gmail.com>
Wed, 14 Aug 2019 20:59:34 +0000 (22:59 +0200)
commit6034b5c703cdb6f55d2847661fd1415184942ee2
tree54cc40867e43a87c59221815a8ff0048ba0d5bc5
parent000182fe4f94a5a6ec139456a2b74f0cdea13b9c
router: close socket upon NETEV_IFINDEX_CHANGE

Make sure the socket is closed in a case where the bridge goes down
as a result of NO-CARRIER on the bridge.
If not present Router Discovery and Router Advertisement will break
permanently after the bridge went down.

Related to  https://github.com/openwrt/odhcpd/issues/135

Signed-off-by: Koen Aerts <aertskoen5@gmail.com>
src/router.c