[PATCH BlueZ] mgmtops: Fix endianness conversion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Flags field has 32-bit size.
---
 plugins/mgmtops.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/plugins/mgmtops.c b/plugins/mgmtops.c
index 22fa329..cedfbd4 100644
--- a/plugins/mgmtops.c
+++ b/plugins/mgmtops.c
@@ -1550,7 +1550,7 @@ static void mgmt_device_found(int sk, uint16_t index, void *buf, size_t len)
 	else
 		eir = ev->eir;
 
-	flags = btohs(ev->flags);
+	flags = btohl(ev->flags);
 
 	ba2str(&ev->addr.bdaddr, addr);
 	DBG("hci%u addr %s, rssi %d flags 0x%04x eir_len %u",
-- 
1.7.10.2

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux