Diff between aa05beff8f18669ae7ce3a6670ca8edaedce399f and d05b8eb5914231ee656079f689a56b5b2001f95c

Changed Files

File Additions Deletions Status
tools/hcidump.c +3 -2 modified

Full Patch

diff --git a/tools/hcidump.c b/tools/hcidump.c
index 0535662..e992d88 100644
--- a/tools/hcidump.c
+++ b/tools/hcidump.c
@@ -178,6 +178,9 @@ static void process_frames(int dev, int sock, int fd, unsigned long flags)
 	char *buf, *ctrl;
 	int len, hdr_size = HCIDUMP_HDR_SIZE;
 
+	if (mode == SERVER)
+		flags |= DUMP_BTSNOOP;
+
 	if (snap_len < SNAP_LEN)
 		snap_len = SNAP_LEN;
 
@@ -213,8 +216,6 @@ static void process_frames(int dev, int sock, int fd, unsigned long flags)
 	if (mode == SERVER) {
 		struct btsnoop_hdr *hdr = (void *) buf;
 
-		flags |= DUMP_BTSNOOP;
-
 		btsnoop_version = 1;
 		btsnoop_type = 1002;