summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhenryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2008-03-13 04:17:46 +0000
committerhenryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2008-03-13 04:17:46 +0000
commit9615190a75ab0304d37701e97947ffe36be2d345 (patch)
tree46685c9553613ab14a91e55cc75121af3a9d92ed
parentc319d646a7961442b94ee798d5a3b3bf62d8a720 (diff)
Add forgotten sanity check
git-svn-id: https://svn.openpcd.org:2342/trunk@451 6dc7ffe9-61d6-0310-9af1-9938baff3ed1
-rw-r--r--openpicc/application/ssc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/openpicc/application/ssc.c b/openpicc/application/ssc.c
index 6c53ebd..e25d982 100644
--- a/openpicc/application/ssc.c
+++ b/openpicc/application/ssc.c
@@ -637,6 +637,7 @@ ssc_handle_t* ssc_open(u_int8_t init_rx, u_int8_t init_tx, enum ssc_mode mode, s
int ssc_recv(ssc_handle_t* sh, ssc_dma_rx_buffer_t* *buffer,unsigned int timeout)
{
if(sh == NULL) return -EINVAL;
+ if(!sh->rx_enabled) return -EINVAL;
taskENTER_CRITICAL();
if(sh->rx_running) {
personal git repositories of Harald Welte. Your mileage may vary