Michael Fischer found and Edgar Grimberg fixed generic crash in timers reproduceable with at91fr40008
git-svn-id: svn://svn.berlios.de/openocd/trunk@663 b42882b7-edfa-0310-969c-e2dbd0fdcd60__archive__
parent
e2ebed86bf
commit
552244724c
|
@ -747,6 +747,8 @@ static int target_call_timer_callbacks_check_time(int checktime)
|
|||
if ((!checktime&&callback->periodic)||
|
||||
(((now.tv_sec >= callback->when.tv_sec) && (now.tv_usec >= callback->when.tv_usec))
|
||||
|| (now.tv_sec > callback->when.tv_sec)))
|
||||
{
|
||||
if(callback->callback != NULL)
|
||||
{
|
||||
callback->callback(callback->priv);
|
||||
if (callback->periodic)
|
||||
|
@ -764,6 +766,7 @@ static int target_call_timer_callbacks_check_time(int checktime)
|
|||
else
|
||||
target_unregister_timer_callback(callback->callback, callback->priv);
|
||||
}
|
||||
}
|
||||
|
||||
callback = next_callback;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue