2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 13:38:26 +00:00

2460 Commits

Author SHA1 Message Date
David Lawrence
9efc87f857 Added level_matches to chains for rbtdb support. 1999-04-20 18:11:07 +00:00
Bob Halley
b8862d5130 add dns_db_attachversion() 1999-04-19 22:51:48 +00:00
Bob Halley
ca3b094a06 add not-already-paused requirement to pause method 1999-04-17 01:37:12 +00:00
Bob Halley
6bb7b678f5 do not pass the version to dns_db_createiterator() 1999-04-16 21:28:00 +00:00
Bob Halley
a8166bf1be versions are no longer part of dbiterators 1999-04-16 21:27:26 +00:00
Bob Halley
828870c41a lint 1999-04-16 21:26:41 +00:00
David Lawrence
ec80744ad6 The ADD_ANCESTOR macro now checks for the required memory, since it is used
in a lot of places now.  It _returns_ if it fails to get the necessary memory,
so any function using it should be returning a dns_result_t.

chain_name moved toward start of file, for inlining by findnode.

move_chain_to_last broke out some functionality of dns_rbtnodechain_last
(which now calls it), also for the benefit of findnode.

dns_rbtnodechain_init on the chain used by addnode.

All of the new_foundname concatenation gook was removed from findnode,
which now just sets foundname by using chain_name.

The chain set up by findnode points to the predecessor when the searched
for name is not found.

nodechain_current was changed to take name, origin and node parameters while
returning a dns_result_t.  This allows the chain returned by findnode to
be named.

The nodechain_{first,last,prev} use nodechain_current to set their
names and origins.  nodechain_next does not need it because it will never
have to do the "set the origin to '.' and remove '.' from names in the
root level" bit.  The root level will never be more than one name, and
everything in the megatree is a successor to that node, so 'next' never
reaches the root level.
1999-04-16 16:12:15 +00:00
David Lawrence
6d74580f08 Documentation for chains. 1999-04-14 14:39:15 +00:00
Bob Halley
8259b7b150 API simplification 1999-04-14 02:33:19 +00:00
Bob Halley
c9a8413dcb Require that only the last reference of a writable version may be committed. 1999-04-13 01:54:02 +00:00
Bob Halley
46d74dd316 fix typo 1999-04-10 00:34:18 +00:00
David Lawrence
33950f0a02 Preliminary work on iterators. 1999-04-09 15:21:15 +00:00
Bob Halley
0370190a68 REQUIRE that target is a valid name in dns_name_getlabelsequence() 1999-04-09 01:27:54 +00:00
Bob Halley
63e6086ef9 pass time to routines which add or create rdatasets 1999-04-09 01:10:19 +00:00
Bob Halley
aa9f70c1e1 add now 1999-04-09 01:09:23 +00:00
Michael Graff
a6a0f27083 msg.h -> message.h, and dns_msg* to dns_message* 1999-04-08 21:13:31 +00:00
Bob Halley
3c11c87769 update comments 1999-04-06 04:15:49 +00:00
Michael Graff
68221c823d add msg functions 1999-04-06 02:18:08 +00:00
Bob Halley
b4055b9666 preliminary dns_db_find() comments 1999-04-05 20:39:50 +00:00
Bob Halley
6e077ae73c add DNS_R_ZONECUT 1999-04-05 20:11:30 +00:00
David Lawrence
da1eb108c6 rbtnode's callback member renamed find_callback. 1999-04-01 15:57:48 +00:00
Bob Halley
ced5499494 add dns_db_find 1999-04-01 04:03:22 +00:00
Bob Halley
d176cbca5b checkpoint 1999-04-01 04:02:33 +00:00
Bob Halley
5bfea18ff8 add dns_rdataslab_merge 1999-04-01 04:00:39 +00:00
Bob Halley
e7b724c23e result types for database searches 1999-04-01 03:59:49 +00:00
David Lawrence
5f50687f61 Changes from Bob, best described in his own barely-edited words:
I added support for the full search algorithm to the RBT database
  code.  The database has some special needs in searching, in particular
  certain nodes need to be examined before the DOWN pointer is followed.

  I solved this problem by adding a 'callback' bit to the node structure.
  When findnode is called, the caller can supply a callback.  Before we go
  DOWN at a node, we call the callback if the callback bit is set at the
  node.  If the callback returns DNS_R_CONTINUE, we proceed.  Otherwise, we
  will stop right there and return what the caller said to return.  I
  added an 'empty_data_ok' flag to findnode as well, so that nodes with
  empty data can be made candidates for partial match status.

  I also wanted to make dns_rbtnodechain_t public, so that a chain could
  be allocated on the stack by the caller.  I added two routines,
  dns_rbtnodechain_init() and dns_rbtnodechain_reset() to work with them.
  The latter routine frees any dynamically allocated memory associated with
  the chain.  The chain structure now contains the memory context.  I also
  moved get_ancestor_mem() and put_ancestor_mem() up in the file, so that
  inlining could be more effective.

  In the nits department, you wrote

                  *node = result == DNS_R_SUCCESS ? current : NULL;

  In the future, please write this instead (the patch has this change in it):

                  if (result == DNS_R_SUCCESS)
                          *node = current;
                  else
                          *node = NULL;
1999-04-01 03:15:54 +00:00
Michael Graff
f9df3b7b03 typo 1999-03-30 03:45:46 +00:00
Michael Graff
952c9d12d0 add DNS_R_MOREDATA for msg library 1999-03-30 03:45:11 +00:00
Michael Graff
b1ddf33030 add msg.h, will change as needed, but Brian needed this now 1999-03-30 03:43:00 +00:00
David Lawrence
194dda8c56 new possible return code for dns_rbt_addnode, DNS_R_NOSPACE. It means
that adding the name would create too many logical levels in the
tree of trees.
1999-03-30 01:57:12 +00:00
Mark Andrews
5f78628b28 Add DNS_R_BADTTL. 1999-03-22 06:18:34 +00:00
David Lawrence
a685d9c3b6 Preliminary implementation of db mounting. 1999-03-18 19:37:30 +00:00
David Lawrence
194f54f4da New parameter to dns_rbt_find{name,node} will return the full dns_name_t
of the node that is found.

Avoids doing any memory allocation when building ancestor chain in 99%
of the cases.
1999-03-16 16:10:36 +00:00
David Lawrence
cdd824cc88 documentation updates.
removed some print support function declarations; made static to rbt.c.
1999-03-12 05:01:42 +00:00
David Lawrence
7f9a18ab45 Move the data pointer further down in the struct, near the second set of
bitfields that are used by RBT DB.
1999-03-11 21:15:12 +00:00
Bob Halley
0cc67b5a2a add DNS_R_UNCHANGED 1999-03-11 20:06:56 +00:00
David Lawrence
f036af2c71 rbtnode struct adapted with more bitfields to represent color,
name attributes, name length, offset length, and number of bytes
of "padding" that are left over when a node is split.

adjusted node splitting algorithm to preserve the original location
of the lower portion of the split node (eg, when a node has "a.b" as
its name and is split into "a" and "b", "a" retains the same address
space as "a.b".)
1999-03-11 18:54:31 +00:00
Bob Halley
efe6d8f066 add dns_db_allrdatasets 1999-03-11 06:00:22 +00:00
Bob Halley
b70e90d44f make current return void 1999-03-11 05:59:40 +00:00
Bob Halley
184aadebb8 rdataset.h is not required 1999-03-11 05:58:56 +00:00
Bob Halley
4054230359 remove old rdataiterator; add rdatasetiter 1999-03-11 05:58:32 +00:00
Bob Halley
84c3294183 improved concatenation 1999-03-11 00:44:17 +00:00
Bob Halley
d7eef25fbe rdataset iterator support 1999-03-11 00:43:43 +00:00
Bob Halley
7a9ded7b5f minor cleanups 1999-03-11 00:43:04 +00:00
Mark Andrews
de10b83a23 * local label offset 255 is reserved.
* don't add domainnames with local compression pointers as
	  valid global compression targets unless edns is high enough.
1999-03-11 00:26:21 +00:00
Bob Halley
4a8b521fd7 remove typedef; add dns_fixedname_name() 1999-03-08 19:31:48 +00:00
Bob Halley
84d3cd8fed add dns_fixedname_t 1999-03-08 19:31:30 +00:00
Bob Halley
8c65ae482a db iterator support 1999-03-08 19:00:55 +00:00
Bob Halley
dbef4f7fb7 add 1999-03-08 19:00:11 +00:00
Bob Halley
544021d7e1 add dbiterator.h and fixedname.h 1999-03-08 18:59:27 +00:00