]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Merge branch 'dev' into ospf3
authorOndrej Zajicek <santiago@crfreenet.org>
Mon, 9 Nov 2009 21:54:39 +0000 (22:54 +0100)
committerOndrej Zajicek <santiago@crfreenet.org>
Mon, 9 Nov 2009 21:54:39 +0000 (22:54 +0100)
1  2 
configure.in
filter/filter.h
lib/socket.h
proto/ospf/config.Y
proto/ospf/ospf.h
sysdep/linux/netlink/netlink.c
sysdep/unix/io.c

diff --cc configure.in
Simple merge
diff --cc filter/filter.h
index 8e0d17934d219f382bc0ae551465c690b235efac,62bad84c17f6d5ade150ba0ceffa08bd9aa137bc..e526a79b3894b5fa1260f881f0f0681f53a695fb
@@@ -85,8 -87,8 +87,9 @@@ char *filter_name(struct filter *filter
  int filter_same(struct filter *new, struct filter *old);
  
  int i_same(struct f_inst *f1, struct f_inst *f2);
+ void f_prefix_get_bounds(struct f_prefix *px, int *l, int *h);
  
 +void f_prefix_get_bounds(struct f_prefix *px, int *l, int *h);
  int val_compare(struct f_val v1, struct f_val v2);
  void val_print(struct f_val v);
  
diff --cc lib/socket.h
index 0ab7d951698691c0ba846144cbf48a82d5d0d974,53e89edd97fcc37ba2388f1687f6ec4953c3ab57..f44e8e88571873eab445fe8ffc68d6521f26537d
@@@ -50,16 -50,9 +50,16 @@@ int sk_send_to(sock *, unsigned len, ip
  void sk_reallocate(sock *);           /* Free and allocate tbuf & rbuf */
  void sk_dump_all(void);
  int sk_set_ttl(sock *s, int ttl);     /* Set TTL for given socket */
 -int sk_set_md5_auth(sock *s, ip_addr a, char *passwd);        /* Add or remove security associations for given passive socket */
 +
 +/* Add or remove security associations for given passive socket */
 +int sk_set_md5_auth(sock *s, ip_addr a, char *passwd);
+ int sk_rx_ready(sock *s);
  
 +/* Prepare UDP or IP socket to multicasting. s->iface and s->ttl must be set */
 +int sk_setup_multicast(sock *s);      
 +int sk_join_group(sock *s, ip_addr maddr);
 +int sk_leave_group(sock *s, ip_addr maddr);
 +
  static inline int
  sk_send_buffer_empty(sock *sk)
  {
index 7b2641b2bcab55248219c5283538a171dd00db59,9529f89a51b019b84455105888fff867a4d5a400..f75e8eb5914e9fdf504857364424b608868c4e6f
@@@ -50,7 -39,8 +50,8 @@@ CF_KEYWORDS(NEIGHBORS, RFC1583COMPAT, S
  CF_KEYWORDS(HELLO, TRANSMIT, PRIORITY, DEAD, NONBROADCAST, POINTOPOINT, TYPE)
  CF_KEYWORDS(NONE, SIMPLE, AUTHENTICATION, STRICT, CRYPTOGRAPHIC)
  CF_KEYWORDS(ELIGIBLE, POLL, NETWORKS, HIDDEN, VIRTUAL, LINK)
- CF_KEYWORDS(RX, BUFFER, LARGE, NORMAL, STUBNET, HIDDEN, SUMMARY, LSADB)
+ CF_KEYWORDS(RX, BUFFER, LARGE, NORMAL, STUBNET, HIDDEN, SUMMARY)
 -CF_KEYWORDS(WAIT, DELAY)
++CF_KEYWORDS(WAIT, DELAY, LSADB)
  
  %type <t> opttext
  
Simple merge
index 6cfb0ba622d2d482a2e585383d1212b4ffc57d40,03d43884aece776acb7444d4cab1322178137bcf..f45fe1596f394000472a070b4b62ed97706c1f97
@@@ -691,18 -682,30 +691,34 @@@ nl_parse_route(struct nlmsghdr *h, int 
          ra.dest = RTD_ROUTER;
          memcpy(&ra.gw, RTA_DATA(a[RTA_GATEWAY]), sizeof(ra.gw));
          ipa_ntoh(ra.gw);
-         ng = neigh_find2(&p->p, &ra.gw, ifa, 0);
-         if (ng && ng->scope)
-         {
-           if (ng->iface != ifa)
-             log(L_WARN "KRT: Route with unexpected iface for %I/%d", net->n.prefix, net->n.pxlen);
-           ra.iface = ng->iface;
-         }
+         if (i->rtm_flags & RTNH_F_ONLINK)
+           {
+             /* route with 'onlink' attribute */
+             ra.iface = if_find_by_index(oif);
+             if (ra.iface == NULL)
+               {
+                 log(L_WARN "Kernel told us to use unknown interface %u for %I/%d",
+                     oif, net->n.prefix, net->n.pxlen);
+                 return;
+               }
+           }
          else
-         {
-           log(L_WARN "Kernel told us to use non-neighbor %I for %I/%d", ra.gw, net->n.prefix, net->n.pxlen);
-           return;
-         }
+           {
 -            /* standard route */
 -            ng = neigh_find(&p->p, &ra.gw, 0);
++            ng = neigh_find2(&p->p, &ra.gw, ifa, 0);
+             if (ng && ng->scope)
 -              ra.iface = ng->iface;
++              {
++                if (ng->iface != ifa)
++                  log(L_WARN "KRT: Route with unexpected iface for %I/%d", net->n.prefix, net->n.pxlen);
++                ra.iface = ng->iface;
++              }
+             else
+               {
+                 log(L_WARN "Kernel told us to use non-neighbor %I for %I/%d", ra.gw, net->n.prefix, net->n.pxlen);
+                 return;
+               }
++
+           }
        }
        else
        {
Simple merge