aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2015-02-17 23:31:06 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2015-02-17 23:31:06 +0100
commit08c735d7520e858868bc2c724572139998e39ada (patch)
tree5c62509e72c1f8590ba0216ef77901dee753c4fc
parent254be95ff2f37df8adec7ce068448ba8abc8d734 (diff)
downloadble-toys-08c735d7520e858868bc2c724572139998e39ada.tar.gz
ble-toys-08c735d7520e858868bc2c724572139998e39ada.tar.bz2
ble-toys-08c735d7520e858868bc2c724572139998e39ada.tar.xz
ble-toys-08c735d7520e858868bc2c724572139998e39ada.zip
o Using cursor instead of size to determine the number of bytes to write.
-rw-r--r--LinuxBluetooth.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/LinuxBluetooth.cpp b/LinuxBluetooth.cpp
index 3efa7e5..2c0bffa 100644
--- a/LinuxBluetooth.cpp
+++ b/LinuxBluetooth.cpp
@@ -159,8 +159,8 @@ void LinuxBluetoothDevice::discoverServices() {
AttPdu::makeReadByGroupType(out, 0x0001, 0xffff, UUID_PRIMARY_SERVICE);
- D << "pdu.size()=" << out.getSize();
- ssize_t written = write(l2cap, buffer, out.getSize());
+ D << "pdu size=" << out.getCursor();
+ ssize_t written = write(l2cap, buffer, out.getCursor());
D << "written=" << written;