[PATCH BlueZ 08/10] proximity: Reduce array size for Tx Power Level

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

 



Tx Power Level characteristic is a signed 8-bits integer which reports
the current transmit power level.
---
 proximity/monitor.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/proximity/monitor.c b/proximity/monitor.c
index 2645321..f22d6f4 100644
--- a/proximity/monitor.c
+++ b/proximity/monitor.c
@@ -55,6 +55,7 @@
 #define POWER_LEVEL_CHR_UUID 0x2A07
 
 #define IMMEDIATE_TIMEOUT	5
+#define TX_POWER_SIZE		1
 
 enum {
 	ALERT_NONE = 0,
@@ -211,7 +212,7 @@ static int write_alert_level(struct monitor *monitor)
 static void tx_power_read_cb(guint8 status, const guint8 *pdu, guint16 plen,
 							gpointer user_data)
 {
-	uint8_t value[ATT_MAX_MTU];
+	uint8_t value[TX_POWER_SIZE];
 	ssize_t vlen;
 
 	if (status != 0) {
-- 
1.7.8.6

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