res_update.h (046c3635cdb274a1f6ccec9933899f5b3bc043a2) | res_update.h (e45764721aedfa6460e1767664864bda9457c10e) |
---|---|
1/* 2 * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC") 3 * Copyright (c) 1999 by Internet Software Consortium, Inc. 4 * 5 * Permission to use, copy, modify, and distribute this software for any 6 * purpose with or without fee is hereby granted, provided that the above 7 * copyright notice and this permission notice appear in all copies. 8 * 9 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES 10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR 12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT 15 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 */ 17 18/* 19 * $Id: res_update.h,v 1.3 2005/04/27 04:56:15 sra Exp $ | 1/* 2 * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC") 3 * Copyright (c) 1999 by Internet Software Consortium, Inc. 4 * 5 * Permission to use, copy, modify, and distribute this software for any 6 * purpose with or without fee is hereby granted, provided that the above 7 * copyright notice and this permission notice appear in all copies. 8 * 9 * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES 10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR 12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT 15 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 */ 17 18/* 19 * $Id: res_update.h,v 1.3 2005/04/27 04:56:15 sra Exp $ |
20 * $FreeBSD$ |
|
20 */ 21 22#ifndef __RES_UPDATE_H 23#define __RES_UPDATE_H 24 25/*! \file */ 26 27#include <sys/types.h> 28#include <arpa/nameser.h> | 21 */ 22 23#ifndef __RES_UPDATE_H 24#define __RES_UPDATE_H 25 26/*! \file */ 27 28#include <sys/types.h> 29#include <arpa/nameser.h> |
29#include <isc/list.h> | |
30#include <resolv.h> 31 32/*% 33 * This RR-like structure is particular to UPDATE. 34 */ 35struct ns_updrec { | 30#include <resolv.h> 31 32/*% 33 * This RR-like structure is particular to UPDATE. 34 */ 35struct ns_updrec { |
36 LINK(struct ns_updrec) r_link, r_glink; | 36 struct { 37 struct ns_updrec *prev; 38 struct ns_updrec *next; 39 } r_link, r_glink; |
37 ns_sect r_section; /*%< ZONE/PREREQUISITE/UPDATE */ 38 char * r_dname; /*%< owner of the RR */ 39 ns_class r_class; /*%< class number */ 40 ns_type r_type; /*%< type number */ 41 u_int32_t r_ttl; /*%< time to live */ 42 u_char * r_data; /*%< rdata fields as text string */ 43 u_int r_size; /*%< size of r_data field */ 44 int r_opcode; /*%< type of operation */ 45 /* following fields for private use by the resolver/server routines */ 46 struct databuf *r_dp; /*%< databuf to process */ 47 struct databuf *r_deldp; /*%< databuf's deleted/overwritten */ 48 u_int r_zone; /*%< zone number on server */ 49}; 50typedef struct ns_updrec ns_updrec; | 40 ns_sect r_section; /*%< ZONE/PREREQUISITE/UPDATE */ 41 char * r_dname; /*%< owner of the RR */ 42 ns_class r_class; /*%< class number */ 43 ns_type r_type; /*%< type number */ 44 u_int32_t r_ttl; /*%< time to live */ 45 u_char * r_data; /*%< rdata fields as text string */ 46 u_int r_size; /*%< size of r_data field */ 47 int r_opcode; /*%< type of operation */ 48 /* following fields for private use by the resolver/server routines */ 49 struct databuf *r_dp; /*%< databuf to process */ 50 struct databuf *r_deldp; /*%< databuf's deleted/overwritten */ 51 u_int r_zone; /*%< zone number on server */ 52}; 53typedef struct ns_updrec ns_updrec; |
51typedef LIST(ns_updrec) ns_updque; | 54typedef struct { 55 ns_updrec *head; 56 ns_updrec *tail; 57} ns_updque; |
52 53#define res_mkupdate __res_mkupdate 54#define res_update __res_update 55#define res_mkupdrec __res_mkupdrec 56#define res_freeupdrec __res_freeupdrec 57#define res_nmkupdate __res_nmkupdate 58#define res_nupdate __res_nupdate 59 | 58 59#define res_mkupdate __res_mkupdate 60#define res_update __res_update 61#define res_mkupdrec __res_mkupdrec 62#define res_freeupdrec __res_freeupdrec 63#define res_nmkupdate __res_nmkupdate 64#define res_nupdate __res_nupdate 65 |
60int res_mkupdate __P((ns_updrec *, u_char *, int)); 61int res_update __P((ns_updrec *)); 62ns_updrec * res_mkupdrec __P((int, const char *, u_int, u_int, u_long)); 63void res_freeupdrec __P((ns_updrec *)); 64int res_nmkupdate __P((res_state, ns_updrec *, u_char *, int)); 65int res_nupdate __P((res_state, ns_updrec *, ns_tsig_key *)); | 66int res_mkupdate(ns_updrec *, u_char *, int); 67int res_update(ns_updrec *); 68ns_updrec * res_mkupdrec(int, const char *, u_int, u_int, u_long); 69void res_freeupdrec(ns_updrec *); 70int res_nmkupdate(res_state, ns_updrec *, u_char *, int); 71int res_nupdate(res_state, ns_updrec *, ns_tsig_key *); |
66 67#endif /*__RES_UPDATE_H*/ 68 69/*! \file */ | 72 73#endif /*__RES_UPDATE_H*/ 74 75/*! \file */ |