about summary refs log tree commit diff
path: root/src/nm-manager.c
diff options
context:
space:
mode:
authorSebastien Bacher <seb128@ubuntu.com>2020-07-27 17:03:33 +0200
committerSebastien Bacher <seb128@ubuntu.com>2020-07-27 17:03:33 +0200
commitb92fc658301eb82b80167a31179c9b839f151b18 (patch)
tree26e2203952eef4ee60e58c6904755e5508150a26 /src/nm-manager.c
parent486e0bef719d78ee55d2166b0bfb4fa684c09854 (diff)
parent136d191f1c96dbae1489fed7c2565f5e1b1f8d40 (diff)
Merge branch 'upstream/latest' of https://salsa.debian.org/utopia-team/network-manager into upstream/latest
Diffstat (limited to 'src/nm-manager.c')
-rw-r--r--src/nm-manager.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/nm-manager.c b/src/nm-manager.c
index ae78b7c9..92112532 100644
--- a/src/nm-manager.c
+++ b/src/nm-manager.c
@@ -3044,10 +3044,9 @@ _get_best_connectivity (NMManager *self, int addr_family)
 		gint64 metric;
 
 		r = nm_device_get_best_default_route (dev, addr_family);
-		if (r) {
-			metric = nm_utils_ip_route_metric_normalize (addr_family,
-			                                             NMP_OBJECT_CAST_IP_ROUTE (r)->metric);
-		} else {
+		if (r)
+			metric = NMP_OBJECT_CAST_IP_ROUTE (r)->metric;
+		else {
 			/* if all devices have no default-route, we still include the best
 			 * of all connectivity state of all the devices. */
 			metric = G_MAXINT64;