More sonarlint work
This commit is contained in:
@@ -123,7 +123,7 @@ timer_process(void)
|
||||
if (timer->flags & TIMER_SPLIT)
|
||||
timer_advance_ex(timer, 0); /* We're splitting a > 1 s period into multiple <= 1 s periods. */
|
||||
else if (timer->callback != NULL) /* Make sure it's no NULL, so that we can have a NULL callback when no operation is needed. */
|
||||
timer->callback(timer->p);
|
||||
timer->callback(timer->priv);
|
||||
}
|
||||
|
||||
timer_target = timer_head->ts.ts32.integer;
|
||||
@@ -159,12 +159,12 @@ timer_init(void)
|
||||
}
|
||||
|
||||
void
|
||||
timer_add(pc_timer_t *timer, void (*callback)(void *p), void *priv, int start_timer)
|
||||
timer_add(pc_timer_t *timer, void (*callback)(void *priv), void *priv, int start_timer)
|
||||
{
|
||||
memset(timer, 0, sizeof(pc_timer_t));
|
||||
|
||||
timer->callback = callback;
|
||||
timer->p = priv;
|
||||
timer->priv = priv;
|
||||
timer->flags = 0;
|
||||
timer->prev = timer->next = NULL;
|
||||
if (start_timer)
|
||||
|
||||
Reference in New Issue
Block a user