]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Nest: Fix bug in export table
authorOndrej Zajicek (work) <santiago@crfreenet.org>
Thu, 31 Oct 2019 00:16:17 +0000 (01:16 +0100)
committerOndrej Zajicek (work) <santiago@crfreenet.org>
Thu, 31 Oct 2019 00:16:17 +0000 (01:16 +0100)
Exported route may be in modified state, we need to get cached one for
rte_same() and rta_clone() to work properly.

nest/rt-table.c

index 429df0ba5ccd01bc0a6d69a53154b231c007279e..d9e4be8ffa2a3463667e1f4112e2dfe93a61d5cb 100644 (file)
@@ -2589,6 +2589,9 @@ rte_update_out(struct channel *c, const net_addr *n, rte *new, rte *old0, int re
   {
     net = net_get(tab, n);
     src = new->attrs->src;
+
+    if (!rta_is_cached(new->attrs))
+      new->attrs = rta_lookup(new->attrs);
   }
   else
   {