"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "edns.c" between
nsd-4.3.5.tar.gz and nsd-4.3.6.tar.gz

About: NSD is an authoritative only, high performance, simple name server daemon.

edns.c  (nsd-4.3.5):edns.c  (nsd-4.3.6)
skipping to change at line 60 skipping to change at line 60
void void
edns_init_record(edns_record_type *edns) edns_init_record(edns_record_type *edns)
{ {
edns->status = EDNS_NOT_PRESENT; edns->status = EDNS_NOT_PRESENT;
edns->position = 0; edns->position = 0;
edns->maxlen = 0; edns->maxlen = 0;
edns->opt_reserved_space = 0; edns->opt_reserved_space = 0;
edns->dnssec_ok = 0; edns->dnssec_ok = 0;
edns->nsid = 0; edns->nsid = 0;
edns->ede = -1; /* -1 means no Extended DNS Error */
edns->ede_text = NULL;
edns->ede_text_len = 0;
} }
/** handle a single edns option in the query */ /** handle a single edns option in the query */
static int static int
edns_handle_option(uint16_t optcode, uint16_t optlen, buffer_type* packet, edns_handle_option(uint16_t optcode, uint16_t optlen, buffer_type* packet,
edns_record_type* edns, struct query* query, nsd_type* nsd) edns_record_type* edns, struct query* query, nsd_type* nsd)
{ {
(void) query; /* in case edns options need the query structure */ (void) query; /* in case edns options need the query structure */
/* handle opt code and read the optlen bytes from the packet */ /* handle opt code and read the optlen bytes from the packet */
switch(optcode) { switch(optcode) {
skipping to change at line 158 skipping to change at line 161
edns->status = EDNS_OK; edns->status = EDNS_OK;
edns->maxlen = opt_class; edns->maxlen = opt_class;
edns->dnssec_ok = opt_flags & DNSSEC_OK_MASK; edns->dnssec_ok = opt_flags & DNSSEC_OK_MASK;
return 1; return 1;
} }
size_t size_t
edns_reserved_space(edns_record_type *edns) edns_reserved_space(edns_record_type *edns)
{ {
/* MIEK; when a pkt is too large?? */ /* MIEK; when a pkt is too large?? */
return edns->status == EDNS_NOT_PRESENT ? 0 : (OPT_LEN + OPT_RDATA + edns return edns->status == EDNS_NOT_PRESENT ? 0
->opt_reserved_space); : (OPT_LEN + OPT_RDATA + edns->opt_reserved_space);
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)