Commit 23782a44 authored by o9000's avatar o9000

Timer: fix use after free

parent 1be85e66
......@@ -384,6 +384,7 @@ void callback_multi_timeout(void *arg)
gettime(&cur_time);
GSList *it = mth->timeout_list;
while (it) {
GSList *next = it->next;
timeout *t = it->data;
if (++t->multi_timeout->current_count >= t->multi_timeout->count_to_expiration) {
t->_callback(t->arg);
......@@ -395,7 +396,7 @@ void callback_multi_timeout(void *arg)
return;
}
}
it = it->next;
it = next;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment