summaryrefslogtreecommitdiffstats
path: root/c/src
diff options
context:
space:
mode:
authorJennifer Averett <Jennifer.Averett@OARcorp.com>1999-11-16 22:46:55 +0000
committerJennifer Averett <Jennifer.Averett@OARcorp.com>1999-11-16 22:46:55 +0000
commit0fa51b5b0a8bfa523974a903f2daa45e797097b5 (patch)
tree2f2c0aee0224fb978fc27e3d25d606cd96a1edf0 /c/src
parentFixed bug. (diff)
downloadrtems-0fa51b5b0a8bfa523974a903f2daa45e797097b5.tar.bz2
Added code to catch the error of suspend count exceding the counter value.
Diffstat (limited to 'c/src')
-rw-r--r--c/src/exec/itron/src/sus_tsk.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/c/src/exec/itron/src/sus_tsk.c b/c/src/exec/itron/src/sus_tsk.c
index 907b708843..91193ed12a 100644
--- a/c/src/exec/itron/src/sus_tsk.c
+++ b/c/src/exec/itron/src/sus_tsk.c
@@ -6,6 +6,7 @@
* $Id$
*/
+#include <limits.h>
#include <itron.h>
#include <rtems/score/thread.h>
@@ -43,6 +44,9 @@ ER sus_tsk(
if ( _Thread_Is_executing( the_thread ) )
_ITRON_return_errorno( E_OBJ );
+ if (the_thread->suspend_count == INT_MAX )
+ _ITRON_return_errorno( E_QOVR );
+
_Thread_Suspend( the_thread );
break;
}