diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2009-06-18 14:32:44 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2009-06-18 14:32:44 +0200 |
commit | 1b3b3e34ecbc281a13d4ca0b99e891ee9c4d5cac (patch) | |
tree | e1212220d75f6ad8c67dfc3412d4ec648fd1b7eb | |
parent | 6f5603badc12dbbf440e8f85b1165cc8f5d671c7 (diff) | |
download | bird-1b3b3e34ecbc281a13d4ca0b99e891ee9c4d5cac.tar bird-1b3b3e34ecbc281a13d4ca0b99e891ee9c4d5cac.zip |
Minor bugfixes.
-rw-r--r-- | lib/ipv6.h | 6 | ||||
-rw-r--r-- | proto/ospf/config.Y | 2 |
2 files changed, 6 insertions, 2 deletions
@@ -31,7 +31,11 @@ typedef struct ipv6_addr { #define IPA_NONE _MI(0,0,0,0) -#define ipa_equal(x,y) (!memcmp(&(x),&(y),sizeof(ip_addr))) +#define ipa_equal(x,y) ({ ip_addr _a=(x), _b=(y); \ + _I0(_a) == _I0(_b) && \ + _I1(_a) == _I1(_b) && \ + _I2(_a) == _I2(_b) && \ + _I3(_a) == _I3(_b); }) #define ipa_nonzero(x) ({ ip_addr _a=(x); (_I0(_a) || _I1(_a) || _I2(_a) || _I3(_a)); }) #define ipa_and(x,y) ({ ip_addr _a=(x), _b=(y); \ _MI(_I0(_a) & _I0(_b), \ diff --git a/proto/ospf/config.Y b/proto/ospf/config.Y index 0f688a7..77ca26c 100644 --- a/proto/ospf/config.Y +++ b/proto/ospf/config.Y @@ -104,7 +104,7 @@ ospf_stubnet: ospf_stubnet_start: prefix { - this_stubnet = cfg_allocz(sizeof(struct stubnet_config)); + this_stubnet = cfg_allocz(sizeof(struct ospf_stubnet_config)); add_tail(&this_area->stubnet_list, NODE this_stubnet); this_stubnet->px = $1; this_stubnet->cost = COST_D; |