2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-31 06:25:31 +00:00

the event action is now responsible for freeing the event memory

This commit is contained in:
Bob Halley
1998-10-28 01:45:43 +00:00
parent b592e197fe
commit b32248301c
3 changed files with 18 additions and 7 deletions

View File

@@ -24,7 +24,8 @@ my_callback(isc_task_t task, isc_event_t event)
for (i = 0; i < 1000000; i++)
j += 100;
printf("task %s (%p): %d\n", name, task, j);
isc_event_free(&event);
return (ISC_FALSE);
}
@@ -33,6 +34,8 @@ my_shutdown(isc_task_t task, isc_event_t event) {
char *name = event->arg;
printf("shutdown %s (%p)\n", name, task);
isc_event_free(&event);
return (ISC_TRUE);
}
@@ -42,6 +45,8 @@ my_tick(isc_task_t task, isc_event_t event)
char *name = event->arg;
printf("task %p tick %s\n", task, name);
isc_event_free(&event);
return (ISC_FALSE);
}