]> git.puffer.fish Git - mirror/frr.git/commitdiff
iBGP multipath is broken if 'bgp deterministic-med' is enabled
authorDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 20 May 2015 00:47:23 +0000 (17:47 -0700)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 20 May 2015 00:47:23 +0000 (17:47 -0700)
bgpd/bgp_aspath.c

index 4406c8b23ab5c94234f84ca0d7ddd6deede8552e..996101a279456240c8bdbf116638c8112628c9ba 100644 (file)
@@ -1417,6 +1417,10 @@ aspath_cmp_left (const struct aspath *aspath1, const struct aspath *aspath2)
   if (!(aspath1 && aspath2))
     return 0;
 
+  /* If both paths are originated in this AS then we do want to compare MED */
+  if (!aspath_count_hops(aspath1) && !aspath_count_hops(aspath2))
+    return 1;
+
   seg1 = aspath1->segments;
   seg2 = aspath2->segments;