summaryrefslogtreecommitdiff
path: root/lib/isc/task_api.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/isc/task_api.c')
-rw-r--r--lib/isc/task_api.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/lib/isc/task_api.c b/lib/isc/task_api.c
index 89065355..4e03db24 100644
--- a/lib/isc/task_api.c
+++ b/lib/isc/task_api.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC")
+ * Copyright (C) 2009, 2010 Internet Systems Consortium, Inc. ("ISC")
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -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.7 2010-12-22 23:46:59 tbox 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.