diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-08-23 11:52:01 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-08-26 10:02:53 +0200 |
commit | 215ccceed3938c2d90a5e44493ac3d016230a502 (patch) | |
tree | 5acc71d435bcdf3fe9cdd2cc641bf9472a60bb54 /cpukit/score/src/threadqextractfifo.c | |
parent | libblock: Avoid uninitialized variable (diff) | |
download | rtems-215ccceed3938c2d90a5e44493ac3d016230a502.tar.bz2 |
score: PR2140: _Thread_queue_Extract()
Return if the executing context performed the extract operation since
interrupts may interfere.
Diffstat (limited to 'cpukit/score/src/threadqextractfifo.c')
-rw-r--r-- | cpukit/score/src/threadqextractfifo.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cpukit/score/src/threadqextractfifo.c b/cpukit/score/src/threadqextractfifo.c index 5038738c12..21c98276ab 100644 --- a/cpukit/score/src/threadqextractfifo.c +++ b/cpukit/score/src/threadqextractfifo.c @@ -25,7 +25,7 @@ #include <rtems/score/threadimpl.h> #include <rtems/score/watchdogimpl.h> -void _Thread_queue_Extract_fifo( +bool _Thread_queue_Extract_fifo( Thread_queue_Control *the_thread_queue __attribute__((unused)), Thread_Control *the_thread ) @@ -36,7 +36,7 @@ void _Thread_queue_Extract_fifo( if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { _ISR_Enable( level ); - return; + return false; } _Chain_Extract_unprotected( &the_thread->Object.Node ); @@ -58,4 +58,5 @@ void _Thread_queue_Extract_fifo( _Thread_MP_Free_proxy( the_thread ); #endif + return true; } |