Handle duplicate IPv6 default routes
After shill adjusts a default IPv6 route to use a metric other than 1024,
the kernel will re-create a duplicate route with a metric of 1024 the
next time it receives a Router Advertisement. Ignore these redundant
routes when shill is trying to adjust the metric, by choosing the
default route with the lowest (most preferred) metric.
BUG=chromium:625229
TEST=run `ip -6 route list` while hot plugging / unplugging a USB
ethernet adapter
Change-Id: I9a775cc2435ba4cb1b7a235cfc8753b5a171df1d
Reviewed-on: https://chromium-review.googlesource.com/358143
Commit-Ready: Kevin Cernekee <cernekee@chromium.org>
Tested-by: Kevin Cernekee <cernekee@chromium.org>
Reviewed-by: Eric Caruso <ejcaruso@chromium.org>
Reviewed-by: Kirtika Ruchandani <kirtika@google.com>
2 files changed