Remove unused structs and line up some comments.
Index: dhcpd.h
===================================================================
RCS file: /cvs/src/usr.sbin/dhcpd/dhcpd.h,v
retrieving revision 1.64
diff -u -p -u -r1.64 dhcpd.h
--- dhcpd.h 24 Apr 2017 14:58:36 -0000 1.64
+++ dhcpd.h 25 Jun 2017 18:36:47 -0000
@@ -54,11 +54,6 @@ struct iaddr {
unsigned char iabuf[16];
};
-struct iaddrlist {
- struct iaddrlist *next;
- struct iaddr addr;
-};
-
#define DEFAULT_HASH_SIZE 97
struct hash_bucket {
@@ -78,25 +73,6 @@ struct option_data {
u_int8_t *data;
};
-struct string_list {
- struct string_list *next;
- char *string;
-};
-
-/* A name server, from /etc/resolv.conf. */
-struct name_server {
- struct name_server *next;
- struct sockaddr_in addr;
- time_t rcdate;
-};
-
-/* A domain search list element. */
-struct domain_search_list {
- struct domain_search_list *next;
- char *domain;
- time_t rcdate;
-};
-
/* A dhcp packet and the pointers to its option values. */
struct packet {
struct dhcp_packet *raw;
@@ -107,12 +83,12 @@ struct packet {
struct iaddr client_addr;
struct interface_info *interface; /* Interface on which packet
was received. */
- struct hardware *haddr; /* Physical link address
- of local sender (maybe gateway). */
+ struct hardware *haddr; /* Physical link address
+ of local sender (maybe gateway). */
struct shared_network *shared_network;
struct option_data options[256];
- int got_requested_address; /* True if client sent the
- dhcp-requested-address option. */
+ int got_requested_address; /* True if client sent the
+ dhcp-requested-address option. */
};
struct hardware {
@@ -174,13 +150,12 @@ struct lease_state {
int max_message_size;
u_int8_t *prl;
int prl_len;
- int got_requested_address; /* True if client sent the
- dhcp-requested-address option. */
- int got_server_identifier; /* True if client sent the
- dhcp-server-identifier option. */
+ int got_requested_address; /* True if client sent the
+ dhcp-requested-address option. */
+ int got_server_identifier; /* True if client sent the
+ dhcp-server-identifier option. */
struct shared_network *shared_network; /* Shared network of
interface
on which request arrived. */
-
u_int32_t xid;
u_int16_t secs;
u_int16_t bootp_flags;
@@ -278,7 +253,7 @@ struct pf_cmd {
struct interface_info {
struct interface_info *next; /* Next interface in list... */
struct shared_network *shared_network;
- /* Networks connected to this interface. */
+ /* Networks connected to this interface. */
struct hardware hw_address; /* Its physical address. */
struct in_addr primary_address; /* Primary interface address. */
char name[IFNAMSIZ]; /* Its name... */
@@ -299,12 +274,6 @@ struct interface_info {
int is_udpsock;
ssize_t (*send_packet)(struct interface_info *, struct dhcp_packet *,
size_t, struct in_addr, struct sockaddr_in *, struct hardware *);
-};
-
-struct hardware_link {
- struct hardware_link *next;
- char name[IFNAMSIZ];
- struct hardware address;
};
struct dhcpd_timeout {