mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-28 04:34:54 -04:00
support for unpurgable events
This commit is contained in:
parent
5d02c5ee4c
commit
3f8744a28f
2 changed files with 9 additions and 4 deletions
|
|
@ -186,7 +186,8 @@ isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first,
|
|||
*
|
||||
* Notes:
|
||||
* Events whose sender is 'sender', and whose type is >= first and
|
||||
* <= last will be purged. A sender of NULL will match any sender.
|
||||
* <= last will be purged, unless they are marked as unpurgable.
|
||||
* A sender of NULL will match any sender.
|
||||
*
|
||||
* Requires:
|
||||
*
|
||||
|
|
@ -206,7 +207,8 @@ isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type);
|
|||
*
|
||||
* Notes:
|
||||
* Events whose sender is 'sender', and whose type is 'type'
|
||||
* will be purged. A sender of NULL will match any sender.
|
||||
* will be purged, unless they are marked as unpurgable.
|
||||
* A sender of NULL will match any sender.
|
||||
*
|
||||
* This function is equivalent to
|
||||
*
|
||||
|
|
|
|||
|
|
@ -346,7 +346,8 @@ isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first,
|
|||
|
||||
/*
|
||||
* Events matching 'sender' and whose type is >= first and
|
||||
* <= last will be purged. sender == NULL means "any sender".
|
||||
* <= last will be purged, unless they are marked as unpurgable.
|
||||
* sender == NULL means "any sender".
|
||||
*
|
||||
* Purging never changes the state of the task.
|
||||
*/
|
||||
|
|
@ -360,7 +361,9 @@ isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first,
|
|||
event = next_event) {
|
||||
next_event = NEXT(event, link);
|
||||
if ((sender == NULL || event->sender == sender) &&
|
||||
event->type >= first && event->type <= last) {
|
||||
event->type >= first &&
|
||||
event->type <= last &&
|
||||
(event->attributes & ISC_EVENTATTR_NOPURGE) == 0) {
|
||||
DEQUEUE(task->events, event, link);
|
||||
ENQUEUE(purgeable, event, link);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue