]> git.puffer.fish Git - mirror/frr.git/commitdiff
Merge branch 'master' into feature/zebra-srcdest 98/head
authorChristian Franke <chris@opensourcerouting.org>
Tue, 31 Jan 2017 15:22:54 +0000 (16:22 +0100)
committerChristian Franke <chris@opensourcerouting.org>
Tue, 31 Jan 2017 15:22:54 +0000 (16:22 +0100)
1  2 
lib/zclient.h
zebra/rib.h
zebra/zebra_rib.c
zebra/zserv.c

diff --cc lib/zclient.h
Simple merge
diff --cc zebra/rib.h
index db564144160fc071f4a4e42dba1c2b51744f9bdd,99903769a294f75c82d08f6ac14c80a591ee73e3..b246b89a53ab03efe64aa9fec36479e6203df9cc
@@@ -349,12 -347,12 +349,12 @@@ extern int rib_add (afi_t afi, safi_t s
                    u_int32_t, u_int32_t, u_char);
  
  extern int rib_add_multipath (afi_t afi, safi_t safi, struct prefix *,
 -                            struct rib *);
 +                            struct prefix_ipv6 *src_p, struct rib *);
  
- extern int rib_delete (afi_t afi, safi_t safi, vrf_id_t vrf_id, int type,
-                      u_short instance, int flags, struct prefix *p,
-                      struct prefix_ipv6 *src_p, union g_addr *gate,
-                      ifindex_t ifindex, u_int32_t table_id);
+ extern void rib_delete (afi_t afi, safi_t safi, vrf_id_t vrf_id, int type,
+                       u_short instance, int flags, struct prefix *p,
 -                      union g_addr *gate, ifindex_t ifindex,
 -                      u_int32_t table_id);
++                      struct prefix_ipv6 *src_p, union g_addr *gate,
++                      ifindex_t ifindex, u_int32_t table_id);
  
  extern struct rib *rib_match (afi_t afi, safi_t safi, vrf_id_t, union g_addr *,
                              struct route_node **rn_out);
index b0b58b738cc52ff47547bb72e4fb142fb083396a,c1c1f897a1e1e1ec3758cfde70c0b8f13934aee6..13418c509e55607abedb02cf7a0de1421558542f
@@@ -2691,10 -2365,10 +2384,10 @@@ rib_add_multipath (afi_t afi, safi_t sa
    return ret;
  }
  
- int
+ void
  rib_delete (afi_t afi, safi_t safi, vrf_id_t vrf_id, int type, u_short instance,
 -          int flags, struct prefix *p, union g_addr *gate, ifindex_t ifindex,
 -          u_int32_t table_id)
 +          int flags, struct prefix *p, struct prefix_ipv6 *src_p,
 +          union g_addr *gate, ifindex_t ifindex, u_int32_t table_id)
  {
    struct route_table *table;
    struct route_node *rn;
  
    /* Apply mask. */
    apply_mask (p);
 +  if (src_p)
 +    apply_mask_ipv6 (src_p);
  
    /* Lookup route node. */
 -  rn = route_node_lookup (table, p);
 +  rn = srcdest_rnode_lookup (table, p, src_p);
    if (! rn)
      {
 +      char dst_buf[PREFIX_STRLEN], src_buf[PREFIX_STRLEN];
 +
 +      prefix2str(p, dst_buf, sizeof(dst_buf));
 +      if (src_p && src_p->prefixlen)
 +        prefix2str(src_p, src_buf, sizeof(src_buf));
 +      else
 +        src_buf[0] = '\0';
 +
        if (IS_ZEBRA_DEBUG_RIB)
 -        zlog_debug ("%u:%s: doesn't exist in rib",
 -                    vrf_id, prefix2str (p, buf1, sizeof(buf1)));
 +        zlog_debug ("%u:%s%s%s doesn't exist in rib",
 +                    vrf_id, dst_buf,
 +                    (src_buf[0] != '\0') ? " from " : "",
 +                    src_buf);
-       return ZEBRA_ERR_RTNOEXIST;
+       return;
      }
  
    /* Lookup same type route. */
diff --cc zebra/zserv.c
Simple merge