Timer: fix use after free
o9000 mrovi9000@gmail.com
1 files changed,
2 insertions(+),
1 deletions(-)
jump to
M
src/util/timer.c
→
src/util/timer.c
@@ -384,6 +384,7 @@ struct timespec cur_time;
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 @@ } else {
return; } } - it = it->next; + it = next; } }