summaryrefslogtreecommitdiff
path: root/print-bt.c
diff options
context:
space:
mode:
Diffstat (limited to 'print-bt.c')
-rw-r--r--print-bt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/print-bt.c b/print-bt.c
index 1f97475f..259f3e5d 100644
--- a/print-bt.c
+++ b/print-bt.c
@@ -33,6 +33,7 @@ static const char rcsid[] _U_ =
#include <string.h>
#include "interface.h"
+#include "extract.h"
#include "addrtoname.h"
#if defined(DLT_BLUETOOTH_HCI_H4_WITH_PHDR) && defined(HAVE_PCAP_BLUETOOTH_H)
@@ -60,7 +61,7 @@ bt_if_print(const struct pcap_pkthdr *h, const u_char *p)
length -= BT_HDRLEN;
p += BT_HDRLEN;
if (eflag)
- (void)printf("hci length %d, direction %s, ", length, (ntohl(hdr->direction)&0x1)?"in":"out");
+ (void)printf("hci length %d, direction %s, ", length, (EXTRACT_32BITS(&hdr->direction)&0x1)?"in":"out");
if (!suppress_default_print)
default_print(p, caplen);