diff options
author | Ondrej Filip <feela@network.cz> | 2004-06-01 15:12:10 +0200 |
---|---|---|
committer | Ondrej Filip <feela@network.cz> | 2004-06-01 15:12:10 +0200 |
commit | 035f6acbfec1e06a207217ae81153b67ced995f3 (patch) | |
tree | 0f30c642631e1a0d370ac45e17c99d13ab4c7332 /proto/ospf/topology.c | |
parent | 8281ff201e1eebe35cb8e7716565361bed77a6cd (diff) | |
download | bird-035f6acbfec1e06a207217ae81153b67ced995f3.tar bird-035f6acbfec1e06a207217ae81153b67ced995f3.zip |
Patch from Andreas Steinmetz <ast@domdv.de>
Diffstat (limited to 'proto/ospf/topology.c')
-rw-r--r-- | proto/ospf/topology.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/proto/ospf/topology.c b/proto/ospf/topology.c index cf4a6e0..29629e2 100644 --- a/proto/ospf/topology.c +++ b/proto/ospf/topology.c @@ -284,6 +284,8 @@ originate_net_lsa(struct ospf_iface *ifa) ifa->nlsa->lsa.age=LSA_MAXAGE; flood_lsa(NULL,NULL,&ifa->nlsa->lsa,po,NULL,ifa->oa,0); s_rem_node(SNODE ifa->nlsa); + if(ifa->nlsa->lsa_body!=NULL) mb_free(ifa->nlsa->lsa_body); + ifa->nlsa->lsa_body=NULL; ospf_hash_delete(ifa->oa->gr, ifa->nlsa); schedule_rtcalc(ifa->oa); ifa->nlsa=NULL; @@ -511,12 +513,12 @@ return (ospf_top_hash_u32(lsaid) + ospf_top_hash_u32((type==LSA_T_NET) ? lsaid : * its used in @ospf_area structure. */ struct top_graph * -ospf_top_new(struct proto_ospf *p) +ospf_top_new(pool *pool, struct proto_ospf *p) { struct top_graph *f; - f = mb_allocz(p->proto.pool, sizeof(struct top_graph)); - f->pool = p->proto.pool; + f = mb_allocz(pool, sizeof(struct top_graph)); + f->pool = pool; f->hash_slab = sl_new(f->pool, sizeof(struct top_hash_entry)); f->hash_order = HASH_DEF_ORDER; ospf_top_ht_alloc(f); |