* SOFTWARE.
*/
-/* $Id: aclconf.c,v 1.18 2000/06/22 21:54:17 tale Exp $ */
+/* $Id: aclconf.c,v 1.18.2.1 2000/08/11 02:13:02 bwelling Exp $ */
#include <config.h>
+#include <isc/mem.h>
#include <isc/string.h> /* Required for HP/UX (and others?) */
#include <isc/util.h>
{
if (strcmp(aclname, dacl->name) == 0) {
dns_acl_attach(dacl, target);
- return ISC_R_SUCCESS;
+ return (ISC_R_SUCCESS);
}
}
/* Not yet converted. Convert now. */
result = dns_acl_fromconfig(cacl->ipml, cctx, ctx, mctx, &dacl);
if (result != ISC_R_SUCCESS)
return (result);
- dacl->name = aclname;
+ dacl->name = isc_mem_strdup(dacl->mctx, aclname);
+ if (dacl->name == NULL)
+ return (ISC_R_NOMEMORY);
ISC_LIST_APPEND(ctx->named_acl_cache, dacl, nextincache);
dns_acl_attach(dacl, target);
return (ISC_R_SUCCESS);