diff --git a/lib/isc/include/isc/log.h b/lib/isc/include/isc/log.h index 2b25979cff..68444c39dd 100644 --- a/lib/isc/include/isc/log.h +++ b/lib/isc/include/isc/log.h @@ -15,7 +15,7 @@ * 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 #define ISC_LOG_H 1 @@ -727,6 +727,10 @@ isc_log_categorybyname(isc_log_t *lctx, const char *name); * Notes: * The string name of a category is not required to be unique. * + * Requires: + * lctx is a valid context. + * name is not NULL. + * * Returns: * 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: * The string name of a module is not required to be unique. * + * Requires: + * lctx is a valid context. + * name is not NULL. + * * Returns: * A pointer to the _first_ isc_logmodule_t structure used by "name". * diff --git a/lib/isc/log.c b/lib/isc/log.c index 7b5e5309de..ef436868d9 100644 --- a/lib/isc/log.c +++ b/lib/isc/log.c @@ -15,7 +15,7 @@ * 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 */ @@ -531,6 +531,7 @@ isc_log_categorybyname(isc_log_t *lctx, const char *name) { isc_logcategory_t *catp; REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); for (catp = lctx->categories; catp->name != NULL; catp++) if (catp->id == UINT_MAX) @@ -585,6 +586,7 @@ isc_log_modulebyname(isc_log_t *lctx, const char *name) { isc_logmodule_t *modp; REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); for (modp = lctx->modules; modp->name != NULL; modp++) if (modp->id == UINT_MAX)