2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-31 14:35:26 +00:00

Allow listening on less than nworkers threads

For some applications, it's useful to not listen on full battery of
threads.  Add workers argument to all isc_nm_listen*() functions and
convenience ISC_NM_LISTEN_ONE and ISC_NM_LISTEN_ALL macros.
This commit is contained in:
Ondřej Surý
2022-03-25 16:44:21 +01:00
parent dad43a128d
commit f55a4d3e55
14 changed files with 214 additions and 164 deletions

View File

@@ -231,8 +231,8 @@ isc_httpdmgr_create(isc_nm_t *nm, isc_mem_t *mctx, isc_sockaddr_t *addr,
isc_refcount_init(&httpdmgr->references, 1);
CHECK(isc_nm_listentcp(nm, addr, httpd_newconn, httpdmgr, 5, NULL,
&httpdmgr->sock));
CHECK(isc_nm_listentcp(nm, ISC_NM_LISTEN_ONE, addr, httpd_newconn,
httpdmgr, 5, NULL, &httpdmgr->sock));
httpdmgr->magic = HTTPDMGR_MAGIC;
*httpdmgrp = httpdmgr;