mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 06:25:31 +00:00
Add and use semantic patch to replace isc_mem_get/allocate+memset
Add new semantic patch to replace the straightfoward uses of: ptr = isc_mem_{get,allocate}(..., size); memset(ptr, 0, size); with the new API call: ptr = isc_mem_{get,allocate}x(..., size, ISC_MEM_ZERO);
This commit is contained in:
@@ -990,9 +990,7 @@ sync_channellist(isc_logconfig_t *lcfg) {
|
||||
|
||||
bytes = lctx->category_count * sizeof(ISC_LIST(isc_logchannellist_t));
|
||||
|
||||
lists = isc_mem_get(lctx->mctx, bytes);
|
||||
|
||||
memset(lists, 0, bytes);
|
||||
lists = isc_mem_getx(lctx->mctx, bytes, ISC_MEM_ZERO);
|
||||
|
||||
if (lcfg->channellist_count != 0) {
|
||||
bytes = lcfg->channellist_count *
|
||||
|
Reference in New Issue
Block a user