diff options
Diffstat (limited to 'includes')
-rw-r--r-- | includes/cdefs.h | 18 | ||||
-rw-r--r-- | includes/config.h.in | 3 | ||||
-rw-r--r-- | includes/dhcp.h | 5 | ||||
-rw-r--r-- | includes/dhcpd.h | 26 | ||||
-rw-r--r-- | includes/dhctoken.h | 5 | ||||
-rw-r--r-- | includes/omapip/omapip_p.h | 2 | ||||
-rw-r--r-- | includes/site.h | 10 |
7 files changed, 53 insertions, 16 deletions
diff --git a/includes/cdefs.h b/includes/cdefs.h index 2f61ed7..eab1c4b 100644 --- a/includes/cdefs.h +++ b/includes/cdefs.h @@ -3,8 +3,8 @@ Standard C definitions... */ /* - * Copyright (c) 2011 by Internet Systems Consortium, Inc. ("ISC") - * Copyright (c) 2004,2009 by Internet Systems Consortium, Inc. ("ISC") + * Copyright (c) 2012 by Internet Systems Consortium, Inc. ("ISC") + * Copyright (c) 2004,2009,2011 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 1996-2003 by Internet Software Consortium * Copyright (c) 1995 RadioMail Corporation. All rights reserved. * @@ -46,15 +46,25 @@ * the warning by the use of void. In conjunction with the use of -Werror * these warnings prohibit the compilation of the package. This macro * allows us to assign the return value to a variable and then ignore it. + * + * __attribute__((unused)) is added for avoiding another warning about set, + * but unused variable. This is produced by unused-but-set-variable switch + * that is enabled by default in gcc 4.6. */ #if !defined(__GNUC__) || (__GNUC__ < 4) #define IGNORE_RET(x) (void) x #else #define IGNORE_RET(x) \ do { \ - int ignore_return; \ - ignore_return = x; \ + int __attribute__((unused)) ignore_return ;\ + ignore_return = x; \ } while (0) #endif +/* This macro is defined to avoid unused-but-set-variable warning + * that is enabled in gcc 4.6 + */ + +#define IGNORE_UNUSED(x) { x = x; } + #endif /* __ISC_DHCP_CDEFS_H__ */ diff --git a/includes/config.h.in b/includes/config.h.in index 2e52f7d..b6014c3 100644 --- a/includes/config.h.in +++ b/includes/config.h.in @@ -91,6 +91,9 @@ /* Define to 1 if you have the <unistd.h> header file. */ #undef HAVE_UNISTD_H +/* Define to the string for a noreturn attribute. */ +#undef ISC_DHCP_NORETURN + /* Define to 1 if the system has 'struct if_laddrconf'. */ #undef ISC_PLATFORM_HAVEIF_LADDRCONF diff --git a/includes/dhcp.h b/includes/dhcp.h index 1af2adf..5eb1ad8 100644 --- a/includes/dhcp.h +++ b/includes/dhcp.h @@ -3,6 +3,7 @@ Protocol structures... */ /* + * Copyright (c) 2011-2012 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 2004-2009 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 1995-2003 by Internet Software Consortium * @@ -79,6 +80,10 @@ struct dhcp_packet { #define HTYPE_ETHER 1 /* Ethernet 10Mbps */ #define HTYPE_IEEE802 6 /* IEEE 802.2 Token Ring... */ #define HTYPE_FDDI 8 /* FDDI... */ +#define HTYPE_INFINIBAND 32 /* IP over Infiniband */ +#define HTYPE_IPMP 255 /* IPMP - random hw address - there + * is no standard for this so we + * just steal a type */ /* Magic cookie validating dhcp options field (and bootp vendor extensions field). */ diff --git a/includes/dhcpd.h b/includes/dhcpd.h index 863a149..f548648 100644 --- a/includes/dhcpd.h +++ b/includes/dhcpd.h @@ -3,7 +3,7 @@ Definitions for dhcpd... */ /* - * Copyright (c) 2004-2011 by Internet Systems Consortium, Inc. ("ISC") + * Copyright (c) 2004-2012 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 1996-2003 by Internet Software Consortium * * Permission to use, copy, modify, and distribute this software for any @@ -436,7 +436,7 @@ struct packet { struct hardware { u_int8_t hlen; - u_int8_t hbuf [17]; + u_int8_t hbuf[21]; }; #if defined(LDAP_CONFIGURATION) @@ -1557,7 +1557,7 @@ struct ipv6_pool { #define DDNS_EXECUTE_NEXT 0x20 #define DDNS_ABORT 0x40 #define DDNS_STATIC_LEASE 0x80 - +#define DDNS_ACTIVE_LEASE 0x100 /* * The following two groups are separate and we could reuse * values but not reusing them may be useful in the future. @@ -1598,7 +1598,7 @@ typedef struct dhcp_ddns_cb { int zone_addr_count; struct dns_zone *zone; - int flags; + u_int16_t flags; TIME timeout; int state; ddns_action_t cur_func; @@ -1950,7 +1950,8 @@ void parse_server_duid_conf(struct parse *cfile); /* ddns.c */ int ddns_updates(struct packet *, struct lease *, struct lease *, struct iasubopt *, struct iasubopt *, struct option_state *); -int ddns_removals(struct lease *, struct iasubopt *, struct dhcp_ddns_cb *); +isc_result_t ddns_removals(struct lease *, struct iasubopt *, + struct dhcp_ddns_cb *, isc_boolean_t); #if defined (TRACING) void trace_ddns_init(void); #endif @@ -3243,7 +3244,10 @@ void make_binding_state_transition (struct lease *); int lease_copy (struct lease **, struct lease *, const char *, int); void release_lease (struct lease *, struct packet *); void abandon_lease (struct lease *, const char *); +#if 0 +/* this appears to be unused and I plan to remove it SAR */ void dissociate_lease (struct lease *); +#endif void pool_timer (void *); int find_lease_by_uid (struct lease **, const unsigned char *, unsigned, const char *, int); @@ -3509,9 +3513,13 @@ isc_result_t release_lease6(struct ipv6_pool *pool, struct iasubopt *lease); isc_result_t decline_lease6(struct ipv6_pool *pool, struct iasubopt *lease); isc_boolean_t lease6_exists(const struct ipv6_pool *pool, const struct in6_addr *addr); +isc_boolean_t lease6_usable(struct iasubopt *lease); +isc_result_t cleanup_lease6(ia_hash_t *ia_table, + struct ipv6_pool *pool, + struct iasubopt *lease, + struct ia_xx *ia); isc_result_t mark_lease_unavailble(struct ipv6_pool *pool, const struct in6_addr *addr); - isc_result_t create_prefix6(struct ipv6_pool *pool, struct iasubopt **pref, unsigned int *attempts, @@ -3543,13 +3551,13 @@ void ddns_cb_forget_zone (dhcp_ddns_cb_t *ddns_cb); //void *key_from_zone(struct dns_zone *zone); isc_result_t -ddns_modify_fwd(dhcp_ddns_cb_t *ddns_cb); +ddns_modify_fwd(dhcp_ddns_cb_t *ddns_cb, const char *file, int line); isc_result_t -ddns_modify_ptr(dhcp_ddns_cb_t *ddns_cb); +ddns_modify_ptr(dhcp_ddns_cb_t *ddns_cb, const char *file, int line); void -ddns_cancel(dhcp_ddns_cb_t *ddns_cb); +ddns_cancel(dhcp_ddns_cb_t *ddns_cb, const char *file, int line); #define MAX_ADDRESS_STRING_LEN \ (sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")) diff --git a/includes/dhctoken.h b/includes/dhctoken.h index 9911d70..6815da4 100644 --- a/includes/dhctoken.h +++ b/includes/dhctoken.h @@ -3,7 +3,7 @@ Tokens for config file lexer and parser. */ /* - * Copyright (c) 2004,2007-2011 by Internet Systems Consortium, Inc. ("ISC") + * Copyright (c) 2004,2007-2012 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 1996-2003 by Internet Software Consortium * * Permission to use, copy, modify, and distribute this software for any @@ -363,7 +363,8 @@ enum dhcp_token { INITIAL_DELAY = 664, GETHOSTBYNAME = 665, PRIMARY6 = 666, - SECONDARY6 = 667 + SECONDARY6 = 667, + TOKEN_INFINIBAND = 668 }; #define is_identifier(x) ((x) >= FIRST_TOKEN && \ diff --git a/includes/omapip/omapip_p.h b/includes/omapip/omapip_p.h index 1fab5a9..51a7b90 100644 --- a/includes/omapip/omapip_p.h +++ b/includes/omapip/omapip_p.h @@ -289,7 +289,7 @@ extern int log_perror; extern void (*log_cleanup) (void); void log_fatal (const char *, ...) - __attribute__((__format__(__printf__,1,2))); + __attribute__((__format__(__printf__,1,2))) ISC_DHCP_NORETURN; int log_error (const char *, ...) __attribute__((__format__(__printf__,1,2))); int log_info (const char *, ...) diff --git a/includes/site.h b/includes/site.h index b78b537..89c77a9 100644 --- a/includes/site.h +++ b/includes/site.h @@ -227,3 +227,13 @@ future. */ #define ACCEPT_LIST_IN_DOMAIN_NAME + +/* In RFC3315 section 17.2.2 stated that if the server was not going + to be able to assign any addresses to any IAs in a subsequent Request + from a client that the server should not include any IAs. This + requirement was removed in an errata from August 2010. Define the + following if you want the pre-errata version. + You should only enable this option if you have clients that + require the original functionality. */ + +/* #define RFC3315_PRE_ERRATA_2010_08 */ |