Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fib: fix adding default route overwriting entire table
[ upstream commit ab1b927cd73e96643cfe93dc2493d03c737b59ae ] When FIB contains any route covering last IP address (255.255.255.255), upon adding a new default route the entire FIB table will be overwritten with corresponding default route next hop. Previous fix added check for ledge against 0 for case if default route is added as a first route, however this check was also erroneously triggered in case when ledge was wrapped around the address space (this would happen if FIB contains any route covering last possible address - 255.255.255.255). This fix prevents wrap around from happening. Fixes: 880bc2b5f3bd ("fib: fix adding default route") Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
- Loading branch information