diff options
author | Shawn Routhier <sar@isc.org> | 2014-04-25 10:57:29 -0700 |
---|---|---|
committer | Shawn Routhier <sar@isc.org> | 2014-04-25 10:57:29 -0700 |
commit | cc5386ec30bde3491a26684754facfd7f3ac9b81 (patch) | |
tree | 3131c1029f897822d84f4148f27d21e0c3c0edba | |
parent | cbcb6b7f6f3f143dc17ee3934befdb0ce1b54e0c (diff) | |
download | isc-dhcp-cc5386ec30bde3491a26684754facfd7f3ac9b81.tar.gz |
[v4_2] Several small patches
Tidy up several small tickets
Correct parsing of DUID from config file, previously the LL type
was put in the wrong place in the DUID string.
[ISC-Bugs #20962]
Add code to parse "do-forward-updates" as well as "do-forward-update"
[ISC-Bugs #31328]
Remove log_priority as it isn't currently used.
[ISC-Bugs #33397]
Increase the size of the buffer used for reading interface information.
[ISC-Bugs #34858]
-rw-r--r-- | RELNOTES | 15 | ||||
-rw-r--r-- | common/conflex.c | 3 | ||||
-rw-r--r-- | common/discover.c | 9 | ||||
-rw-r--r-- | common/parse.c | 6 | ||||
-rw-r--r-- | includes/omapip/omapip_p.h | 1 | ||||
-rw-r--r-- | omapip/errwarn.c | 9 | ||||
-rw-r--r-- | server/confpars.c | 4 |
7 files changed, 33 insertions, 14 deletions
@@ -43,6 +43,21 @@ ISC DHCP is open source software maintained by Internet Systems Consortium. This product includes cryptographic software written by Eric Young (eay@cryptsoft.com). + + Changes since 4.2.6 + +- Tidy up several small tickets + Correct parsing of DUID from config file, previously the LL type + was put in the wrong place in the DUID string. + [ISC-Bugs #20962] + Add code to parse "do-forward-updates" as well as "do-forward-update" + Thanks to Jiri Popelka at Red Hat. + [ISC-Bugs #31328] + Remove log_priority as it isn't currently used. + [ISC-Bugs #33397] + Increase the size of the buffer used for reading interface information. + [ISC-Bugs #34858] + Changes since 4.2.6rc1 - None diff --git a/common/conflex.c b/common/conflex.c index c39e91de..5bb2ea14 100644 --- a/common/conflex.c +++ b/common/conflex.c @@ -892,6 +892,9 @@ intern(char *atom, enum dhcp_token dfv) { if (!strcasecmp(atom + 7, "list")) return DOMAIN_LIST; } + if (!strcasecmp (atom + 1, "o-forward-updates")) + return DO_FORWARD_UPDATE; + /* do-forward-update is included for historical reasons */ if (!strcasecmp (atom + 1, "o-forward-update")) return DO_FORWARD_UPDATE; if (!strcasecmp (atom + 1, "ebug")) diff --git a/common/discover.c b/common/discover.c index 4b40a70a..aeb2fc50 100644 --- a/common/discover.c +++ b/common/discover.c @@ -29,6 +29,9 @@ #include "dhcpd.h" +/* length of line we can read from the IF file, 256 is too small in some cases */ +#define IF_LINE_LENGTH 1024 + #define BSD_COMP /* needed on Solaris for SIOCGLIFNUM */ #include <sys/ioctl.h> #include <errno.h> @@ -408,7 +411,7 @@ struct iface_info { */ int begin_iface_scan(struct iface_conf_list *ifaces) { - char buf[256]; + char buf[IF_LINE_LENGTH]; int len; int i; @@ -481,7 +484,7 @@ begin_iface_scan(struct iface_conf_list *ifaces) { */ static int next_iface4(struct iface_info *info, int *err, struct iface_conf_list *ifaces) { - char buf[256]; + char buf[IF_LINE_LENGTH]; int len; char *p; char *name; @@ -605,7 +608,7 @@ next_iface4(struct iface_info *info, int *err, struct iface_conf_list *ifaces) { */ static int next_iface6(struct iface_info *info, int *err, struct iface_conf_list *ifaces) { - char buf[256]; + char buf[IF_LINE_LENGTH]; int len; char *p; char *name; diff --git a/common/parse.c b/common/parse.c index fa357619..db2e1d0d 100644 --- a/common/parse.c +++ b/common/parse.c @@ -5900,10 +5900,10 @@ int parse_warn (struct parse *cfile, const char *fmt, ...) lexbuf [lix] = 0; #ifndef DEBUG - syslog (log_priority | LOG_ERR, "%s", mbuf); - syslog (log_priority | LOG_ERR, "%s", cfile -> token_line); + syslog (LOG_ERR, "%s", mbuf); + syslog (LOG_ERR, "%s", cfile -> token_line); if (cfile -> lexchar < 81) - syslog (log_priority | LOG_ERR, "%s^", lexbuf); + syslog (LOG_ERR, "%s^", lexbuf); #endif if (log_perror) { diff --git a/includes/omapip/omapip_p.h b/includes/omapip/omapip_p.h index 30a778ed..788c91e6 100644 --- a/includes/omapip/omapip_p.h +++ b/includes/omapip/omapip_p.h @@ -278,7 +278,6 @@ OMAPI_ARRAY_TYPE_DECL(omapi_connection, omapi_connection_object_t); isc_result_t omapi_handle_clear(omapi_handle_t); -extern int log_priority; extern int log_perror; extern void (*log_cleanup) (void); diff --git a/omapip/errwarn.c b/omapip/errwarn.c index 3e917ef1..d68af04a 100644 --- a/omapip/errwarn.c +++ b/omapip/errwarn.c @@ -42,7 +42,6 @@ int log_perror = -1; #else int log_perror = 1; #endif -int log_priority; void (*log_cleanup) (void); #define CVT_BUF_MAX 1023 @@ -65,7 +64,7 @@ void log_fatal (const char * fmt, ... ) va_end (list); #ifndef DEBUG - syslog (log_priority | LOG_ERR, "%s", mbuf); + syslog (LOG_ERR, "%s", mbuf); #endif /* Also log it to stderr? */ @@ -114,7 +113,7 @@ int log_error (const char * fmt, ...) va_end (list); #ifndef DEBUG - syslog (log_priority | LOG_ERR, "%s", mbuf); + syslog (LOG_ERR, "%s", mbuf); #endif if (log_perror) { @@ -141,7 +140,7 @@ int log_info (const char *fmt, ...) va_end (list); #ifndef DEBUG - syslog (log_priority | LOG_INFO, "%s", mbuf); + syslog (LOG_INFO, "%s", mbuf); #endif if (log_perror) { @@ -168,7 +167,7 @@ int log_debug (const char *fmt, ...) va_end (list); #ifndef DEBUG - syslog (log_priority | LOG_DEBUG, "%s", mbuf); + syslog (LOG_DEBUG, "%s", mbuf); #endif if (log_perror) { diff --git a/server/confpars.c b/server/confpars.c index 684f9c12..2729f778 100644 --- a/server/confpars.c +++ b/server/confpars.c @@ -5419,7 +5419,7 @@ parse_server_duid_conf(struct parse *cfile) { } duid.data = (unsigned char *)duid.buffer->data; putUShort(duid.buffer->data, DUID_LL); - putULong(duid.buffer->data + 2, ll_type); + putUShort(duid.buffer->data + 2, ll_type); memcpy(duid.buffer->data + 4, ll_addr.data, ll_addr.len); @@ -5483,7 +5483,7 @@ parse_server_duid_conf(struct parse *cfile) { } duid.data = (unsigned char *)duid.buffer->data; putUShort(duid.buffer->data, DUID_LLT); - putULong(duid.buffer->data + 2, ll_type); + putUShort(duid.buffer->data + 2, ll_type); putULong(duid.buffer->data + 4, llt_time); memcpy(duid.buffer->data + 8, ll_addr.data, ll_addr.len); |