Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH BlueZ] Fix batostr(): return the bdaddr in the right order
@ 2011-09-14 15:46 Antonio Ospite
  2011-09-14 17:53 ` Marcel Holtmann
  0 siblings, 1 reply; 5+ messages in thread
From: Antonio Ospite @ 2011-09-14 15:46 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Antonio Ospite

lib/bluetooth.c::batostr() is returning the bdaddr reversed, fix this
and put more arguments on the same line to look more like ba2str().
---
 lib/bluetooth.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/lib/bluetooth.c b/lib/bluetooth.c
index db7bbe1..8509620 100644
--- a/lib/bluetooth.c
+++ b/lib/bluetooth.c
@@ -55,8 +55,7 @@ char *batostr(const bdaddr_t *ba)
 		return NULL;
 
 	sprintf(str, "%2.2X:%2.2X:%2.2X:%2.2X:%2.2X:%2.2X",
-		ba->b[0], ba->b[1], ba->b[2],
-		ba->b[3], ba->b[4], ba->b[5]);
+		ba->b[5], ba->b[4], ba->b[3], ba->b[2], ba->b[1], ba->b[0]);
 
 	return str;
 }
-- 
1.7.5.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-09-19 11:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-14 15:46 [PATCH BlueZ] Fix batostr(): return the bdaddr in the right order Antonio Ospite
2011-09-14 17:53 ` Marcel Holtmann
2011-09-14 19:08   ` Antonio Ospite
2011-09-19 11:02     ` Antonio Ospite
2011-09-19 11:14       ` Marcel Holtmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox