From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH BlueZ 2/3] monitor: Fix not decoding control frames
Date: Thu, 20 Apr 2017 15:32:32 +0300 [thread overview]
Message-ID: <20170420123233.8747-2-luiz.dentz@gmail.com> (raw)
In-Reply-To: <20170420123233.8747-1-luiz.dentz@gmail.com>
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
In order to enable decoding control frames packet_monitor needs to check
if the index is set to HCI_DEV_NONE since that will call packet_ctrl_open
which setups the ctrl and assign it a cookie.
---
monitor/packet.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/monitor/packet.c b/monitor/packet.c
index e5f2a32..b14a82d 100644
--- a/monitor/packet.c
+++ b/monitor/packet.c
@@ -3866,10 +3866,11 @@ void packet_monitor(struct timeval *tv, struct ucred *cred,
uint16_t manufacturer;
const char *ident;
- if (index_filter && index_number != index)
- return;
-
- index_current = index;
+ if (index != HCI_DEV_NONE) {
+ if (index_filter && index_number != index)
+ return;
+ index_current = index;
+ }
if (tv && time_offset == ((time_t) -1))
time_offset = tv->tv_sec;
--
2.9.3
next prev parent reply other threads:[~2017-04-20 12:32 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-20 12:32 [PATCH BlueZ 1/3] monitor: Add frame number support Luiz Augusto von Dentz
2017-04-20 12:32 ` Luiz Augusto von Dentz [this message]
2017-04-20 12:32 ` [PATCH BlueZ 3/3] client: Always start an agent Luiz Augusto von Dentz
2017-04-20 12:52 ` Marcel Holtmann
2017-04-20 13:13 ` Luiz Augusto von Dentz
2017-04-20 12:57 ` [PATCH BlueZ 1/3] monitor: Add frame number support Marcel Holtmann
2017-04-20 13:20 ` Luiz Augusto von Dentz
-- strict thread matches above, loose matches on Subject: below --
2017-04-23 20:14 [PATCH BlueZ 1/3] monitor: Add frame counter support Luiz Augusto von Dentz
2017-04-23 20:14 ` [PATCH BlueZ 2/3] monitor: Fix not decoding control frames Luiz Augusto von Dentz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170420123233.8747-2-luiz.dentz@gmail.com \
--to=luiz.dentz@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox