Diff between 68959ca0d3c664693737a2c48be70c63c5591a13 and 7899d71215470c67e0035bc292c21d847e2a9be7

Changed Files

File Additions Deletions Status
android/hidhost.c +2 -1 modified
src/eir.c +2 -1 modified
tools/l2test.c +3 -1 modified
tools/rctest.c +3 -1 modified
tools/scotest.c +3 -1 modified

Full Patch

diff --git a/android/hidhost.c b/android/hidhost.c
index 4226f69..81e7eb8 100644
--- a/android/hidhost.c
+++ b/android/hidhost.c
@@ -38,6 +38,7 @@
 #include "lib/sdp.h"
 #include "lib/sdp_lib.h"
 #include "src/shared/mgmt.h"
+#include "src/shared/util.h"
 #include "src/sdp-client.h"
 #include "src/uuid-helper.h"
 #include "profiles/input/uhid_copy.h"
@@ -1066,7 +1067,7 @@ static void bt_hid_get_report(const void *buf, uint16_t len)
 
 	if (cmd->buf_size > 0) {
 		req[0] = req[0] | HID_GET_REPORT_SIZE_FIELD;
-		bt_put_le16(cmd->buf_size, &req[2]);
+		put_le16(cmd->buf_size, &req[2]);
 	}
 
 	fd = g_io_channel_unix_get_fd(dev->ctrl_io);
diff --git a/src/eir.c b/src/eir.c
index cc1c5dd..be83718 100644
--- a/src/eir.c
+++ b/src/eir.c
@@ -37,6 +37,7 @@
 #include <bluetooth/hci.h>
 #include <bluetooth/sdp.h>
 
+#include "src/shared/util.h"
 #include "uuid-helper.h"
 #include "eir.h"
 
@@ -473,7 +474,7 @@ int eir_create_oob(const bdaddr_t *addr, const char *name, uint32_t cod,
 	eir_total_len += eir_optional_len;
 
 	/* store total length */
-	bt_put_le16(eir_total_len, data);
+	put_le16(eir_total_len, data);
 
 	return eir_total_len;
 }
diff --git a/tools/l2test.c b/tools/l2test.c
index 0993f74..8e62227 100644
--- a/tools/l2test.c
+++ b/tools/l2test.c
@@ -47,6 +47,8 @@
 #include <bluetooth/hci_lib.h>
 #include <bluetooth/l2cap.h>
 
+#include "src/shared/util.h"
+
 #define NIBBLE_TO_ASCII(c)  ((c) < 0x0a ? (c) + 0x30 : (c) + 0x57)
 
 #define BREDR_DEFAULT_PSM	0x1011
@@ -977,7 +979,7 @@ static void do_send(int sk)
 	seq = 0;
 	while ((num_frames == -1) || (num_frames-- > 0)) {
 		bt_put_le32(seq, buf);
-		bt_put_le16(data_size, buf + 4);
+		put_le16(data_size, buf + 4);
 
 		seq++;
 
diff --git a/tools/rctest.c b/tools/rctest.c
index 9281392..98fe792 100644
--- a/tools/rctest.c
+++ b/tools/rctest.c
@@ -47,6 +47,8 @@
 #include <bluetooth/sdp.h>
 #include <bluetooth/sdp_lib.h>
 
+#include "src/shared/util.h"
+
 /* Test modes */
 enum {
 	SEND,
@@ -568,7 +570,7 @@ static void do_send(int sk)
 	seq = 0;
 	while ((num_frames == -1) || (num_frames-- > 0)) {
 		bt_put_le32(seq, buf);
-		bt_put_le16(data_size, buf + 4);
+		put_le16(data_size, buf + 4);
 
 		seq++;
 
diff --git a/tools/scotest.c b/tools/scotest.c
index 227287d..13b9602 100644
--- a/tools/scotest.c
+++ b/tools/scotest.c
@@ -40,6 +40,8 @@
 #include <bluetooth/bluetooth.h>
 #include <bluetooth/sco.h>
 
+#include "src/shared/util.h"
+
 /* Test modes */
 enum {
 	SEND,
@@ -346,7 +348,7 @@ static void send_mode(char *svr)
 	seq = 0;
 	while (1) {
 		bt_put_le32(seq, buf);
-		bt_put_le16(data_size, buf + 4);
+		put_le16(data_size, buf + 4);
 
 		seq++;