Disable scheduling ub_fd()

This commit is contained in:
Willem Toorop 2016-01-12 16:38:10 +01:00
parent 4fd8d3dddd
commit 2a6318afd2
2 changed files with 5 additions and 1 deletions

View File

@ -1280,17 +1280,21 @@ getdns_context_request_count_changed(getdns_context *context)
DEBUG_SCHED("gc_request_count_changed "
"-> ub schedule(el_ev = %p, el_ev->ev = %p)\n",
&context->ub_event, context->ub_event.ev);
#ifndef USE_WINSOCK
context->extension->vmt->schedule(
context->extension, ub_fd(context->unbound_ctx),
TIMEOUT_FOREVER, &context->ub_event);
#endif
}
else if (context->ub_event.ev) /* Only test if count == 0! */ {
DEBUG_SCHED("gc_request_count_changed "
"-> ub clear(el_ev = %p, el_ev->ev = %p)\n",
&context->ub_event, context->ub_event.ev);
#ifndef USE_WINSOCK
context->extension->vmt->clear(
context->extension, &context->ub_event);
#endif
}
}

View File

@ -68,7 +68,7 @@ getdns_sync_loop_init(getdns_context *context, getdns_sync_loop *loop)
_getdns_default_eventloop_init(&loop->loop);
#ifdef HAVE_LIBUNBOUND
#if defined(HAVE_LIBUNBOUND) && !defined(USE_WINSOCK)
loop->ub_event.userarg = loop->context;
loop->ub_event.read_cb = _getdns_context_ub_read_cb;
loop->ub_event.write_cb = NULL;