]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Merge commit 'd429bc5c841a8e9d4c81786973edfa56d20a407e' into thread-next
authorMaria Matejka <mq@ucw.cz>
Wed, 13 Jul 2022 10:54:20 +0000 (12:54 +0200)
committerMaria Matejka <mq@ucw.cz>
Wed, 13 Jul 2022 10:54:20 +0000 (12:54 +0200)
1  2 
proto/babel/babel.c
proto/bgp/attrs.c
proto/ospf/ospf.c
proto/pipe/pipe.c
proto/radv/radv.c
sysdep/unix/krt.c

index 8b6abacb9d77ebeadfe8e8d7015f46838fc67287,7ea1aba89431579bb06a869ff6ee417761185177..00b9aa795ba21c8e8224010d92c8303130598cc6
@@@ -2257,15 -2256,11 +2257,15 @@@ babel_kick_timer(struct babel_proto *p
  
  
  static int
- babel_preexport(struct channel *c, struct rte *new)
+ babel_preexport(struct channel *C, struct rte *new)
  {
-   if (new->src->proto != c->proto)
 -  struct rta *a = new->attrs;
++  if (new->src->proto != C->proto)
 +    return 0;
 +
    /* Reject our own unreachable routes */
 -  if ((a->dest == RTD_UNREACHABLE) && (new->src->proto == C->proto))
 +  eattr *ea = ea_find(new->attrs, &ea_gen_nexthop);
 +  struct nexthop_adata *nhad = (void *) ea->u.ptr;
 +  if (!NEXTHOP_IS_REACHABLE(nhad))
      return -1;
  
    return 0;
Simple merge
Simple merge
index 351db36ba3652aef2450a8930352c14e5b212c89,1f1ad85744199fd4ca0fa535a7f239e20de85de6..8af6de8146bebc4a223d31ccca60d93654158472
@@@ -73,24 -97,12 +73,24 @@@ pipe_rt_notify(struct proto *P, struct 
  }
  
  static int
- pipe_preexport(struct channel *c, rte *e)
+ pipe_preexport(struct channel *C, rte *e)
  {
-   struct pipe_proto *p = (void *) c->proto;
 -  struct proto *pp = e->sender->proto;
++  struct pipe_proto *p = (void *) C->proto;
  
 -  if (pp == C->proto)
 -    return -1;        /* Avoid local loops automatically */
 +  /* Avoid direct loopbacks */
-   if (e->sender == c->in_req.hook)
++  if (e->sender == C->in_req.hook)
 +    return -1;
 +
 +  /* Indirection check */
 +  uint max_generation = ((struct pipe_config *) p->p.cf)->max_generation;
 +  if (e->generation >= max_generation)
 +  {
 +    log_rl(&p->rl_gen, L_ERR "Route overpiped (%u hops of %u configured in %s) in table %s: %N %s/%u:%u",
-       e->generation, max_generation, c->proto->name,
-       c->table->name, e->net, e->src->proto->name, e->src->private_id, e->src->global_id);
++      e->generation, max_generation, C->proto->name,
++      C->table->name, e->net, e->src->proto->name, e->src->private_id, e->src->global_id);
 +
 +    return -1;
 +  }
  
    return 0;
  }
Simple merge
index 67d19cbb4bea1584711c693756b6419f5bfedac2,be547a936faa17d5b4ae651e95955d412f03b2aa..46b5a51d4b4cf453730618cf8f65a50f38e03976
@@@ -681,9 -889,10 +681,9 @@@ krt_scan_timer_kick(struct krt_proto *p
   */
  
  static int
- krt_preexport(struct channel *c, rte *e)
+ krt_preexport(struct channel *C, rte *e)
  {
-   if (e->src->proto == c->proto)
 -  // struct krt_proto *p = (struct krt_proto *) P;
+   if (e->src->proto == C->proto)
      return -1;
  
    if (!krt_capable(e))