+4070. [bug] Fix a segfault in nslookup in a query such as
+ "nslookup isc.org AMS.SNS-PB.ISC.ORG -all".
+ [RT #38548]
+
4069. [doc] Reorganize options in the nsupdate man page.
[RT #38516]
get_address(char *host, in_port_t myport, isc_sockaddr_t *sockaddr) {
int count;
isc_result_t result;
+ isc_boolean_t is_running;
- isc_app_block();
+ is_running = isc_app_isrunning();
+ if (is_running)
+ isc_app_block();
result = bind9_getaddresses(host, myport, sockaddr, 1, &count);
- isc_app_unblock();
+ if (is_running)
+ isc_app_unblock();
if (result != ISC_R_SUCCESS)
return (result);
static void
setoption(char *opt) {
- if (strncasecmp(opt, "all", 4) == 0) {
+ if (strncasecmp(opt, "all", 3) == 0) {
show_settings(ISC_TRUE, ISC_FALSE);
} else if (strncasecmp(opt, "class=", 6) == 0) {
if (testclass(&opt[6]))
static isc_mutex_t createlock;
static isc_once_t once = ISC_ONCE_INIT;
static isc_appctxcreatefunc_t appctx_createfunc = NULL;
+static isc_boolean_t is_running = ISC_FALSE;
#define ISCAPI_APPMETHODS_VALID(m) ISC_MAGIC_VALID(m, ISCAPI_APPMETHODS_MAGIC)
isc_result_t
isc_app_run() {
- if (isc_bind9)
- return (isc__app_run());
+ if (isc_bind9) {
+ isc_result_t result;
+
+ is_running = ISC_TRUE;
+ result = isc__app_run();
+ is_running = ISC_FALSE;
+
+ return (result);
+ }
return (ISC_R_NOTIMPLEMENTED);
}
+isc_boolean_t
+isc_app_isrunning() {
+ return (is_running);
+}
+
isc_result_t
isc_app_shutdown(void) {
if (isc_bind9)
*\li ISC_R_RELOAD Reload has been requested.
*/
+isc_boolean_t
+isc_app_isrunning(void);
+/*!<
+ * \brief Return if the ISC library application is running.
+ *
+ * Returns:
+ *\li ISC_TRUE App is running.
+ *\li ISC_FALSE App is not running.
+ */
+
isc_result_t
isc_app_ctxshutdown(isc_appctx_t *ctx);
isc_app_ctxstart
isc_app_ctxsuspend
isc_app_finish
+isc_app_isrunning
isc_app_onrun
isc_app_register
isc_app_reload