diff options
Diffstat (limited to 'lib/dns/rbt.c')
-rw-r--r-- | lib/dns/rbt.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/dns/rbt.c b/lib/dns/rbt.c index 6c14e8e..c733e50 100644 --- a/lib/dns/rbt.c +++ b/lib/dns/rbt.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007-2009, 2011 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: rbt.c,v 1.146 2009-10-27 04:46:58 marka Exp $ */ +/* $Id: rbt.c,v 1.146.278.2 2011-03-12 04:59:17 tbox Exp $ */ /*! \file */ @@ -718,6 +718,7 @@ dns_rbt_findnode(dns_rbt_t *rbt, dns_name_t *name, dns_name_t *foundname, */ compared = dns_namereln_none; last_compared = NULL; + order = 0; } dns_fixedname_init(&fixedcallbackname); @@ -1084,6 +1085,7 @@ dns_rbt_findnode(dns_rbt_t *rbt, dns_name_t *name, dns_name_t *foundname, ¤t_name, &order, &common_labels); + POST(compared); last_compared = current; @@ -1526,7 +1528,7 @@ rehash(dns_rbt_t *rbt) { oldsize = rbt->hashsize; oldtable = rbt->hashtable; - rbt->hashsize *= 2 + 1; + rbt->hashsize = rbt->hashsize * 2 + 1; rbt->hashtable = isc_mem_get(rbt->mctx, rbt->hashsize * sizeof(dns_rbtnode_t *)); if (rbt->hashtable == NULL) { @@ -1683,6 +1685,7 @@ dns_rbt_addonlevel(dns_rbtnode_t *node, dns_rbtnode_t *current, int order, } child = root; + POST(child); dns_name_init(&add_name, add_offsets); NODENAME(node, &add_name); |