Page MenuHomeFreeBSD

Fix ifa refcount leak during route addition.
ClosedPublic

Authored by melifaro on Feb 12 2021, 8:57 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Dec 5, 6:23 AM
Unknown Object (File)
Nov 14 2024, 4:15 PM
Unknown Object (File)
Sep 30 2024, 8:08 AM
Unknown Object (File)
Sep 29 2024, 1:06 AM
Unknown Object (File)
Sep 12 2024, 6:02 PM
Unknown Object (File)
Sep 9 2024, 2:13 AM
Unknown Object (File)
Sep 7 2024, 2:25 PM
Unknown Object (File)
Sep 5 2024, 8:04 AM
Subscribers

Details

Reviewers
rstone
Group Reviewers
network
Summary

Routing code relies on stable ifa's during route creation.
This is needed due to the fact that nhop objects stores (referenced) ifa object for the whole nhop object lifetime.

To avoid the situation when ifa gets scheduled for the deleted during the route addition process, rt_getifa_fib() references found ifa as soon as possible.

Plug refcount leak by freeing ifa reference immediately after creating nexthop, regardless of the result.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 36943
Build 33832: arc lint + arc unit