2009-12-10 Joel Sherrill <joel.sherrill@OARcorp.com>

PR 1482
	* posix/src/timersettime.c: Exit dispatching critical section.
This commit is contained in:
Joel Sherrill
2009-12-10 22:15:26 +00:00
parent 7af806ac22
commit a06a3f712d
2 changed files with 13 additions and 4 deletions

View File

@@ -1,3 +1,8 @@
2009-12-10 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 1482
* posix/src/timersettime.c: Exit dispatching critical section.
2009-12-10 Joel Sherrill <joel.sherrill@OARcorp.com> 2009-12-10 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 1480/cpukit PR 1480/cpukit

View File

@@ -102,11 +102,15 @@ int timer_settime(
_POSIX_Timer_TSR, _POSIX_Timer_TSR,
ptimer ptimer
); );
if ( !activated ) if ( !activated ) {
_Thread_Enable_dispatch();
return 0; return 0;
}
/* The timer has been started and is running */ /*
/* return the old ones in "ovalue" */ * The timer has been started and is running. So we return the
* old ones in "ovalue"
*/
if ( ovalue ) if ( ovalue )
*ovalue = ptimer->timer_data; *ovalue = ptimer->timer_data;
ptimer->timer_data = normalize; ptimer->timer_data = normalize;
@@ -114,7 +118,7 @@ int timer_settime(
/* Indicate that the time is running */ /* Indicate that the time is running */
ptimer->state = POSIX_TIMER_STATE_CREATE_RUN; ptimer->state = POSIX_TIMER_STATE_CREATE_RUN;
_TOD_Get( &ptimer->time ); _TOD_Get( &ptimer->time );
_Thread_Enable_dispatch(); _Thread_Enable_dispatch();
return 0; return 0;
#if defined(RTEMS_MULTIPROCESSING) #if defined(RTEMS_MULTIPROCESSING)