diff options
author | Dean Camera <dean@fourwalledcubicle.com> | 2010-05-21 08:01:41 +0000 |
---|---|---|
committer | Dean Camera <dean@fourwalledcubicle.com> | 2010-05-21 08:01:41 +0000 |
commit | 58a0ee67a396622922d873d0625c993d2d5f9e57 (patch) | |
tree | 370c30583667ee11dfe15b4c4de9f74bbf592ff7 /Demos/Host/Incomplete/BluetoothHost | |
parent | 92bebc457f679902a0816cc10b753673016a1014 (diff) | |
download | lufa-58a0ee67a396622922d873d0625c993d2d5f9e57.tar.gz lufa-58a0ee67a396622922d873d0625c993d2d5f9e57.tar.bz2 lufa-58a0ee67a396622922d873d0625c993d2d5f9e57.zip |
Oops - when adding a sequence header to the SDP response, the size value needs to be cleared, not the buffer pointer.
Diffstat (limited to 'Demos/Host/Incomplete/BluetoothHost')
-rw-r--r-- | Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.c | 3 | ||||
-rw-r--r-- | Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.h | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.c b/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.c index 227f7583d..3f16ad1d8 100644 --- a/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.c +++ b/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.c @@ -224,6 +224,9 @@ static void ServiceDiscovery_ProcessServiceSearchAttribute(SDP_PDUHeader_t* SDPH ResponsePacket.SDPHeader.TransactionID = SDPHeader->TransactionID; ResponsePacket.SDPHeader.ParameterLength = (ResponsePacket.AttributeListByteCount + sizeof(ResponsePacket.AttributeListByteCount)); + BT_SDP_DEBUG(1, ">> Service Search Attribute Response"); + BT_SDP_DEBUG(2, "-- Total Parameter Length: 0x%04X", ResponsePacket.SDPHeader.ParameterLength); + Bluetooth_SendPacket(&ResponsePacket, (sizeof(ResponsePacket.SDPHeader) + ResponsePacket.SDPHeader.ParameterLength), Channel); } diff --git a/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.h b/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.h index 58f7d8766..50d15ad3a 100644 --- a/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.h +++ b/Demos/Host/Incomplete/BluetoothHost/Lib/ServiceDiscoveryProtocol.h @@ -120,10 +120,9 @@ *BufferPos += 1; uint16_t* SizePos = (uint16_t*)*BufferPos; - *SizePos = 0; - - **BufferPos += 2; + *BufferPos += 2; + *SizePos = 0; return SizePos; } |