[PATCH 1/4] Simplify ba2oui function

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

 



---
 lib/bluetooth.c |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diff --git a/lib/bluetooth.c b/lib/bluetooth.c
index 875119b..d064f9e 100644
--- a/lib/bluetooth.c
+++ b/lib/bluetooth.c
@@ -109,11 +109,7 @@ int str2ba(const char *str, bdaddr_t *ba)
 
 int ba2oui(const bdaddr_t *ba, char *str)
 {
-	uint8_t b[6];
-
-	baswap((bdaddr_t *) b, ba);
-
-	return sprintf(str, "%2.2X-%2.2X-%2.2X", b[0], b[1], b[2]);
+	return sprintf(str, "%2.2X-%2.2X-%2.2X", ba->b[5], ba->b[4], ba->b[3]);
 }
 
 int bachk(const char *str)
-- 
1.7.0.4

--
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