2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-30 14:07:59 +00:00

removed the port member from dns_c_ctrl_t; the port is put in the sockaddr.

This commit is contained in:
David Lawrence
2000-07-10 11:28:31 +00:00
parent 838281ed55
commit d4868faf3f
2 changed files with 6 additions and 12 deletions

View File

@@ -15,7 +15,7 @@
* SOFTWARE.
*/
/* $Id: confctl.c,v 1.23 2000/07/07 23:11:42 brister Exp $ */
/* $Id: confctl.c,v 1.24 2000/07/10 11:28:30 tale Exp $ */
#include <config.h>
@@ -115,20 +115,15 @@ dns_c_ctrlinet_new(isc_mem_t *mem, dns_c_ctrl_t **control,
REQUIRE(control != NULL);
ctrl = isc_mem_get(mem, sizeof *ctrl);
if (ctrl == NULL) {
if (ctrl == NULL)
return (ISC_R_NOMEMORY);
}
ctrl->magic = DNS_C_CONFCTL_MAGIC;
ctrl->mem = mem;
ctrl->control_type = dns_c_inet_control;
isc_sockaddr_setport(&addr, port);
ctrl->u.inet_v.addr = addr;
ctrl->u.inet_v.port = port;
ctrl->keyidlist = NULL;
if (keylist != NULL) {
ctrl->keyidlist = keylist;
}
ctrl->keyidlist = keylist;
if (copy) {
res = dns_c_ipmatchlist_copy(mem,
@@ -235,7 +230,7 @@ dns_c_ctrl_print(FILE *fp, int indent, dns_c_ctrl_t *ctl) {
(void) indent;
if (ctl->control_type == dns_c_inet_control) {
port = ctl->u.inet_v.port;
port = isc_sockaddr_getport(&ctl->u.inet_v.addr);
iml = ctl->u.inet_v.matchlist;
fprintf(fp, "inet ");

View File

@@ -15,7 +15,7 @@
* SOFTWARE.
*/
/* $Id: confctl.h,v 1.17 2000/07/07 23:11:47 brister Exp $ */
/* $Id: confctl.h,v 1.18 2000/07/10 11:28:31 tale Exp $ */
#ifndef DNS_CONFCTL_H
#define DNS_CONFCTL_H 1
@@ -86,7 +86,6 @@ struct dns_c_ctrl {
union {
struct {
isc_sockaddr_t addr;
in_port_t port;
dns_c_ipmatchlist_t *matchlist;
} inet_v; /* when control_type == dns_c_inet_control */
struct {