From: Andreas Gustafsson Date: Wed, 29 Nov 2000 20:18:57 +0000 (+0000) Subject: pullup: X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=093d42a77011d7ab48c43d7e2a364ac6bdfe6927;p=thirdparty%2Fbind9.git pullup: 581. [bug] log severity was not being correctly processed. [RT #485] --- diff --git a/CHANGES b/CHANGES index f5994b34600..56b874e45b4 100644 --- a/CHANGES +++ b/CHANGES @@ -1,7 +1,15 @@ + 581. [bug] Log severity was not being correctly processed. + [RT #485] + 574. [bug] TSIG signed queries sent by the resolver would fail to have their responses validated and would leak memory. + 573. [bug] The journal files of IXFRed slave zones were + inadvertantly discarded on server reload, causing + "journal out of sync with zone" errors on subsequent + reloads. [RT #482] + 572. [bug] Quoted strings were not accepted as key names in address match lists. diff --git a/bin/named/logconf.c b/bin/named/logconf.c index 5b80f058d64..32c52a7aa24 100644 --- a/bin/named/logconf.c +++ b/bin/named/logconf.c @@ -15,7 +15,7 @@ * SOFTWARE. */ -/* $Id: logconf.c,v 1.22 2000/06/23 17:59:08 tale Exp $ */ +/* $Id: logconf.c,v 1.22.2.1 2000/11/29 20:18:57 gson Exp $ */ #include @@ -95,6 +95,7 @@ channel_fromconf(dns_c_logchan_t *cchan, isc_logconfig_t *lctx) { unsigned int type; unsigned int flags = 0; int level; + dns_c_logseverity_t severity; type = ISC_LOG_TONULL; switch (cchan->ctype) { @@ -173,7 +174,34 @@ channel_fromconf(dns_c_logchan_t *cchan, isc_logconfig_t *lctx) { } level = ISC_LOG_INFO; - (void)dns_c_logchan_getdebuglevel(cchan, &level); + if (dns_c_logchan_getseverity(cchan, &severity) == ISC_R_SUCCESS) { + switch (severity) { + case dns_c_log_critical: + level = ISC_LOG_CRITICAL; + break; + case dns_c_log_error: + level = ISC_LOG_ERROR; + break; + case dns_c_log_warn: + level = ISC_LOG_WARNING; + break; + case dns_c_log_notice: + level = ISC_LOG_NOTICE; + break; + case dns_c_log_info: + level = ISC_LOG_INFO; + break; + case dns_c_log_debug: + (void)dns_c_logchan_getdebuglevel(cchan, &level); + break; + case dns_c_log_dynamic: + level = ISC_LOG_DYNAMIC; + break; + default: + level = ISC_LOG_INFO; + break; + } + } result = isc_log_createchannel(lctx, cchan->name, type, level, &dest, flags);