Lines Matching defs:header
88 * This is the header for map-format RBT images. It is populated,
90 * Writing this last (with zeros in the header area initially) will ensure
91 * that the header is only valid when the RBT image is also valid.
119 * step one: write out a zeroed header of 1024 bytes
125 * step three: write out the header, adding the information that will be
143 match_header_version(file_header_t *header);
160 getparent(dns_rbtnode_t *node, file_header_t *header) {
162 adjusted_address += node->parent_is_relative * (uintptr_t)header;
168 getleft(dns_rbtnode_t *node, file_header_t *header) {
170 adjusted_address += node->left_is_relative * (uintptr_t)header;
176 getright(dns_rbtnode_t *node, file_header_t *header) {
178 adjusted_address += node->right_is_relative * (uintptr_t)header;
184 getdown(dns_rbtnode_t *node, file_header_t *header) {
186 adjusted_address += node->down_is_relative * (uintptr_t)header;
192 getdata(dns_rbtnode_t *node, file_header_t *header) {
194 adjusted_address += node->data_is_relative * (uintptr_t)header;
471 * Write out a zeroed header as a placeholder. Doing this ensures
503 * Write out the real header, including NodeDump version information
513 file_header_t header;
519 memset(&header, 0, sizeof(file_header_t));
520 memmove(header.version1, FILE_VERSION, sizeof(header.version1));
521 memmove(header.version2, FILE_VERSION, sizeof(header.version2));
522 header.first_node_offset = first_node_offset;
523 header.ptrsize = (isc_uint32_t) sizeof(void *);
524 header.bigendian = (1 == htonl(1)) ? 1 : 0;
527 header.rdataset_fixed = 1;
529 header.rdataset_fixed = 0;
532 header.nodecount = rbt->nodecount;
534 header.crc = crc;
539 CHECK(isc_stdio_write(&header, 1, sizeof(file_header_t), file, NULL));
550 match_header_version(file_header_t *header) {
553 if (memcmp(header->version1, FILE_VERSION,
554 sizeof(header->version1)) != 0 ||
555 memcmp(header->version2, FILE_VERSION,
556 sizeof(header->version1)) != 0)
632 hexdump("node header", (unsigned char*) &temp_node,
735 /* Write dummy header */
755 /* Serialize header */
783 dns_rbtnode_t header;
805 /* memorize header contents prior to fixup */
806 memmove(&header, n, sizeof(header));
874 hexdump("node header", (unsigned char *) &header,
878 isc_crc64_update(crc, (const isc_uint8_t *) &header,
895 file_header_t *header;
909 header = (file_header_t *)((char *)base_address + header_offset);
910 if (!match_header_version(header)) {
916 if (header->rdataset_fixed != 1) {
922 if (header->rdataset_fixed != 0) {
928 if (header->ptrsize != (isc_uint32_t) sizeof(void *)) {
934 if (header->bigendian != host_big_endian) {
939 /* Copy other data items from the header into our rbt. */
941 header_offset + header->first_node_offset);
943 if ((header->nodecount * sizeof(dns_rbtnode_t)) > filesize) {
947 rehash(rbt, header->nodecount);
958 if (header->crc != crc) {
963 if (header->nodecount != rbt->nodecount) {
3677 * - the dumpfile header also contains a nodecount that is unsigned