mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-01 23:25:38 +00:00
require name != NULL in *byname
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
* SOFTWARE.
|
* SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id: log.h,v 1.12 2000/03/04 00:43:40 tale Exp $ */
|
/* $Id: log.h,v 1.13 2000/03/04 16:41:14 tale Exp $ */
|
||||||
|
|
||||||
#ifndef ISC_LOG_H
|
#ifndef ISC_LOG_H
|
||||||
#define ISC_LOG_H 1
|
#define ISC_LOG_H 1
|
||||||
@@ -727,6 +727,10 @@ isc_log_categorybyname(isc_log_t *lctx, const char *name);
|
|||||||
* Notes:
|
* Notes:
|
||||||
* The string name of a category is not required to be unique.
|
* The string name of a category is not required to be unique.
|
||||||
*
|
*
|
||||||
|
* Requires:
|
||||||
|
* lctx is a valid context.
|
||||||
|
* name is not NULL.
|
||||||
|
*
|
||||||
* Returns:
|
* Returns:
|
||||||
* A pointer to the _first_ isc_logcategory_t structure used by "name".
|
* A pointer to the _first_ isc_logcategory_t structure used by "name".
|
||||||
*
|
*
|
||||||
@@ -741,6 +745,10 @@ isc_log_modulebyname(isc_log_t *lctx, const char *name);
|
|||||||
* Notes:
|
* Notes:
|
||||||
* The string name of a module is not required to be unique.
|
* The string name of a module is not required to be unique.
|
||||||
*
|
*
|
||||||
|
* Requires:
|
||||||
|
* lctx is a valid context.
|
||||||
|
* name is not NULL.
|
||||||
|
*
|
||||||
* Returns:
|
* Returns:
|
||||||
* A pointer to the _first_ isc_logmodule_t structure used by "name".
|
* A pointer to the _first_ isc_logmodule_t structure used by "name".
|
||||||
*
|
*
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
* SOFTWARE.
|
* SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id: log.c,v 1.19 2000/03/04 00:43:38 tale Exp $ */
|
/* $Id: log.c,v 1.20 2000/03/04 16:39:54 tale Exp $ */
|
||||||
|
|
||||||
/* Principal Authors: DCL */
|
/* Principal Authors: DCL */
|
||||||
|
|
||||||
@@ -531,6 +531,7 @@ isc_log_categorybyname(isc_log_t *lctx, const char *name) {
|
|||||||
isc_logcategory_t *catp;
|
isc_logcategory_t *catp;
|
||||||
|
|
||||||
REQUIRE(VALID_CONTEXT(lctx));
|
REQUIRE(VALID_CONTEXT(lctx));
|
||||||
|
REQUIRE(name != NULL);
|
||||||
|
|
||||||
for (catp = lctx->categories; catp->name != NULL; catp++)
|
for (catp = lctx->categories; catp->name != NULL; catp++)
|
||||||
if (catp->id == UINT_MAX)
|
if (catp->id == UINT_MAX)
|
||||||
@@ -585,6 +586,7 @@ isc_log_modulebyname(isc_log_t *lctx, const char *name) {
|
|||||||
isc_logmodule_t *modp;
|
isc_logmodule_t *modp;
|
||||||
|
|
||||||
REQUIRE(VALID_CONTEXT(lctx));
|
REQUIRE(VALID_CONTEXT(lctx));
|
||||||
|
REQUIRE(name != NULL);
|
||||||
|
|
||||||
for (modp = lctx->modules; modp->name != NULL; modp++)
|
for (modp = lctx->modules; modp->name != NULL; modp++)
|
||||||
if (modp->id == UINT_MAX)
|
if (modp->id == UINT_MAX)
|
||||||
|
Reference in New Issue
Block a user