Limit the memory pool for the uvreqs

Set the number of maximum free items for the uvreq memory pool to 64.
This commit is contained in:
Ondřej Surý 2023-08-16 16:55:02 +02:00
parent f36e118b9a
commit 0c9cf8fabb
No known key found for this signature in database
GPG key ID: 2820F37E873DEA41

View file

@ -239,6 +239,7 @@ isc_netmgr_create(isc_mem_t *mctx, isc_loopmgr_t *loopmgr, isc_nm_t **netmgrp) {
isc_mempool_create(worker->mctx, sizeof(isc__nm_uvreq_t),
&worker->uvreq_pool);
isc_mempool_setfreemax(worker->uvreq_pool, ISC_NM_UVREQS_MAX);
isc_loop_attach(loop, &worker->loop);
isc_loop_teardown(loop, networker_teardown, worker);