From 93048c3a1a3f8a86d8f5be1bd3409f77e9802d6e Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Tue, 14 Mar 2006 18:25:35 +0000 Subject: Fix broken behavior with EVT_CMD_STATUS --- src/hci.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/hci.c b/src/hci.c index 9e81653c..d0c2394c 100644 --- a/src/hci.c +++ b/src/hci.c @@ -977,13 +977,13 @@ int hci_send_req(int dd, struct hci_request *r, int to) if (cs->opcode != opcode) continue; - if (cs->status) { - errno = EIO; - goto failed; - } - - if (r->event != EVT_CMD_STATUS) + if (r->event != EVT_CMD_STATUS) { + if (cs->status) { + errno = EIO; + goto failed; + } break; + } r->rlen = MIN(len, r->rlen); memcpy(r->rparam, ptr, r->rlen); -- cgit