mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-10-27 12:48:22 +00:00
timer: fix missing fired set
This commit is contained in:
@@ -15,7 +15,7 @@ static void insert(timer_t *timer, timerentry_t *entry, time_t us) {
|
||||
} else {
|
||||
timerentry_t *search = timer->queue;
|
||||
|
||||
while(search) {
|
||||
while (search) {
|
||||
if (search->next == NULL) { // if last entry in the queue
|
||||
entry->next = NULL;
|
||||
search->next = entry;
|
||||
@@ -38,6 +38,8 @@ static void timercheck(timer_t *timer) {
|
||||
|
||||
if (entry->repeatus)
|
||||
insert(timer, entry, entry->repeatus);
|
||||
else
|
||||
entry->fired = true;
|
||||
|
||||
dpc_enqueue(&entry->dpc, entry->fn, entry->arg);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user