From aa836a6d1ad6d85611c99590050396f923c9c275 Mon Sep 17 00:00:00 2001 From: Michel Pollet Date: Fri, 1 Jun 2012 23:14:11 +0100 Subject: [PATCH] core: Cycle timer small fix Makes it better on threaded GL on OSX Signed-off-by: Michel Pollet --- simavr/sim/sim_cycle_timers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simavr/sim/sim_cycle_timers.c b/simavr/sim/sim_cycle_timers.c index 5b362e9..71ab161 100644 --- a/simavr/sim/sim_cycle_timers.c +++ b/simavr/sim/sim_cycle_timers.c @@ -68,11 +68,11 @@ avr_cycle_timer_insert( if (cnt) memmove(&pool->timer[inserti + 1], &pool->timer[inserti], cnt * sizeof(avr_cycle_timer_slot_t)); - pool->count++; pool->timer[inserti].timer = timer; pool->timer[inserti].param = param; pool->timer[inserti].when = when; + pool->count++; DEBUG(printf("%s %2d/%2d when %7d %p/%p\n", __func__, inserti, pool->count, (int)(when - avr->cycle), timer, param);) DUMP(pool, "after"); } -- 2.39.5