Example #1
0
/**
 * Release resources associated with the timer.
 * Calls timer->destroy. If success and if this is a heap allocated
 * timer, then it will be freed.
 */
int as_timer_destroy(as_timer * timer) {
    int rc = as_util_hook(destroy, 1, timer);
    if ( rc == 0 && timer->is_malloc ) {
        cf_free(timer);
    }
    return rc;
}
Example #2
0
uint64_t as_timer_timeslice(const as_timer * timer) {
	if (timer == NULL) return 0;
	return as_util_hook(timeslice, false, timer);
}
Example #3
0
bool as_timer_timedout(const as_timer * timer) {
	if (timer == NULL) return 0;
	return as_util_hook(timedout, false, timer);
}
/**
 * Module Destroyer.
 */
int as_module_destroy(as_module * m) {
    return as_util_hook(destroy, 1, m);
}