diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2007-12-04 14:48:41 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2007-12-04 14:48:41 +0000 |
commit | bef9d20d8eb9186a4f03c397ae880be7cad7efe1 (patch) | |
tree | b8d0c31e8029a97469a2a7f83a1a6e99194ee19a /src/chqueues.c | |
parent | 443c9c7db609dd2ac895bd605837f1c028076ada (diff) | |
download | ChibiOS-bef9d20d8eb9186a4f03c397ae880be7cad7efe1.tar.gz ChibiOS-bef9d20d8eb9186a4f03c397ae880be7cad7efe1.tar.bz2 ChibiOS-bef9d20d8eb9186a4f03c397ae880be7cad7efe1.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@126 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'src/chqueues.c')
-rw-r--r-- | src/chqueues.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/chqueues.c b/src/chqueues.c index d0412598b..ddc2cfdff 100644 --- a/src/chqueues.c +++ b/src/chqueues.c @@ -125,8 +125,11 @@ t_msg chIQGetTimeout(Queue *qp, t_time time) { chSysLock();
- if ((msg = chSemWaitTimeoutS(&qp->q_sem, time)) < RDY_OK)
+ if ((msg = chSemWaitTimeoutS(&qp->q_sem, time)) < RDY_OK) {
+
+ chSysUnlock();
return msg;
+ }
b = *qp->q_rdptr++;
if (qp->q_rdptr >= qp->q_top)
qp->q_rdptr = qp->q_buffer;
|