Commit 7a54dade authored by Mark Andrews's avatar Mark Andrews

2998. [func] Add isc_task_beginexclusive and isc_task_endexclusive

                        to the task api. [RT #22776]
parent b427cc26
2998. [func] Add isc_task_beginexclusive and isc_task_endexclusive
to the task api. [RT #22776]
2997. [func] named -V now reports the OpenSSL and libxml2 verions
it was compiled against. [RT #22687]
......
......@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: task.c,v 1.114 2010/12/04 13:25:59 marka Exp $ */
/* $Id: task.c,v 1.115 2010/12/22 05:19:01 marka Exp $ */
/*! \file
* \author Principal Author: Bob Halley
......@@ -233,9 +233,7 @@ static struct isc__taskmethods {
* The following are defined just for avoiding unused static functions.
*/
#ifndef BIND9
void *purgeevent, *unsendrange,
*getname, *gettag, *getcurrenttime, *beginexclusive,
*endexclusive;
void *purgeevent, *unsendrange, *getname, *gettag, *getcurrenttime;
#endif
} taskmethods = {
{
......@@ -249,14 +247,15 @@ static struct isc__taskmethods {
isc__task_shutdown,
isc__task_setname,
isc__task_purge,
isc__task_purgerange
isc__task_purgerange,
isc__task_beginexclusive,
isc__task_endexclusive
}
#ifndef BIND9
,
(void *)isc__task_purgeevent, (void *)isc__task_unsendrange,
(void *)isc__task_getname, (void *)isc__task_gettag,
(void *)isc__task_getcurrenttime, (void *)isc__task_beginexclusive,
(void *)isc__task_endexclusive
(void *)isc__task_getcurrenttime
#endif
};
......
......@@ -14,7 +14,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: task_api.c,v 1.5 2009/09/02 23:48:02 tbox Exp $ */
/* $Id: task_api.c,v 1.6 2010/12/22 05:19:02 marka Exp $ */
#include <config.h>
......@@ -187,6 +187,21 @@ isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, void *tag)
return (task->methods->purgeevents(task, sender, type, tag));
}
isc_result_t
isc_task_beginexclusive(isc_task_t *task) {
REQUIRE(ISCAPI_TASK_VALID(task));
return (task->methods->beginexclusive(task));
}
void
isc_task_endexclusive(isc_task_t *task) {
REQUIRE(ISCAPI_TASK_VALID(task));
task->methods->endexclusive(task);
}
/*%
* This is necessary for libisc's internal timer implementation. Other
* implementation might skip implementing this.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment