Claudio Takahasi
84244c3c59
Add host/little endian/host conversion functions for uint128_t values
...
ATT Multi-octet fields uses little endian format. htob128 converts from
host to little endian. btoh128 converts from little endian.
2010-08-09 18:06:44 -04:00
Claudio Takahasi
df3c8e1ebb
Add GATT SDP record for sdptool
...
Extend sdptool to allow to add GATT SDP record. Devices that support
GATT over BR/EDR shall publish GATT record. This implementation intend
to be a reference for GATT SDP record creation and it can be a helper
to GATT servers implemented outside BlueZ.
2010-08-09 18:06:43 -04:00
Elvis Pfützenreuter
15b2bfd69b
Fix sdp_get_supp_feat function
...
In case of string data items, value is a pointer by itself.
2010-06-18 11:12:36 +03:00
Gustavo F. Padovan
a554d3a656
Fix redundant null check on calling free()
...
Issues found by smatch static check: http://smatch.sourceforge.net/
2010-06-08 15:57:25 +08:00
Elvis Pfützenreuter
d48df6f540
Change MDP profile name and macros to HDP
2010-06-04 11:24:10 +03:00
José Antonio Santos Cadenas
1d1154156d
Fix list parsing bug in sdp_set_supp_features
...
When the data is a string or a sequence, it is not ok to dereference
data->val because it is already a pointer. Additionally a lengths
variable is added because the strings are not terminated with '\0' and
otherwise it would not be possible to know their length.
2010-04-28 22:47:59 +03:00
Marcel Holtmann
bd3ebad37b
Make some UUID parameters const
2010-04-28 10:40:48 +02:00
Marcel Holtmann
d108edd5cd
Remove another bunch of pointless casting attempts
2010-04-28 10:36:55 +02:00
Santiago Carot-Nemesio
114cb3f810
Add memory checks whenever memory is allocated in SDP
...
This patch checks memory allocated with malloc and removes uneccessary
(**void) castings.
2010-04-28 10:37:24 +03:00
Santiago Carot Nemesio
f58df2db7a
Use NULL instead of 0 for functions returning a pointer
2010-04-27 17:56:40 +03:00
Santiago Carot Nemesio
400772d67b
Remove some blanks spaces in sdp source code.
2010-04-27 17:56:14 +03:00
Marcel Holtmann
9184e2eeb7
Update copyright information
2010-01-01 17:08:17 -08:00
José Antonio Santos Cadenas
3faf12fdb7
Add SDP functions for HDP support
2009-12-14 12:23:23 -08:00
Johan Hedberg
8232558057
Fix variable initializations
2009-10-02 11:19:01 +02:00
Johan Hedberg
ec43fff7e7
Fix unnecessary NULL checks
2009-10-02 11:18:54 +02:00
Marcel Holtmann
a5b1e3d02c
Switch to a full non-recursive build system
2009-08-23 00:40:59 -07:00
Luiz Augusto von Dentz
68a3563bf4
Introduce sdp_uuid_cmp to sdp_lib.h.
...
sdp_uuid_cmp converts the given uuid to 128 and then compares using
sdp_uuid128_cmp.
2009-08-12 00:31:29 +03:00
Luiz Augusto von Dentz
206da78a25
Fix bug which could cause buffer overruns.
2009-07-21 17:13:30 -03:00
Luiz Augusto von Dentz
f008103206
Fix possible memory leak.
2009-07-16 10:21:50 -03:00
Luiz Augusto von Dentz
135e87fb2f
Fix possible leak or crash on gen_dataseq_pdu in case of out of memory.
2009-07-16 09:24:37 -03:00
Johan Hedberg
8b54704a51
Remove unnecessary empty line
2009-05-19 01:39:40 +03:00
Luiz Augusto von Dentz
6996a497c4
Mark sdp_gen_buffer static.
2009-05-18 18:53:50 -03:00
Luiz Augusto von Dentz
2db52b2d09
Make sure sdp allocates enough memory when generating pdu.
2009-05-18 16:42:32 +03:00
Luiz Augusto von Dentz
04b4fc2e62
Fix dead assignment.
...
Value stored to 'rsp_count' is never read.
2009-04-01 11:59:53 -03:00
Luiz Augusto von Dentz
58a7ff1f9e
Fix dead assignment.
...
Value stored to 'curr' is never read.
2009-04-01 11:59:50 -03:00
Luiz Augusto von Dentz
5e1f7cb4d8
Fix dead assignments.
...
Values stored to 'status' is never read.
2009-04-01 11:59:50 -03:00
Bastien Nocera
eb101261ee
Fix sdp_copy_record truncating strings with NULLs
...
When a record's attribute contains embed NULLs in the string,
sdp_data_alloc() falls back to doing an strlen() on the
string, instead of taking its existing length into account.
2009-03-13 15:07:44 -03:00
Johan Hedberg
b5e64e37e1
Fix uninitialized memory issue
2009-02-13 17:43:38 +02:00
Marcel Holtmann
cb0b4b761c
Fix SDP code to allow compilation with -Wsign-compare
2009-01-30 00:10:55 +01:00
Johan Hedberg
8f159d4498
Coding style fixes
2009-01-13 18:13:20 +02:00
Luiz Augusto von Dentz
0472c96f47
Fix bug on sdp_copy_record.
...
sdp_copy_record where not copying uuid data correctly.
2009-01-12 16:19:49 -03:00
Marcel Holtmann
fb333f1c88
Update copyright information
2009-01-01 19:33:20 +01:00
Marcel Holtmann
80d17627cc
Remove unused sdp_create_base_uuid function
2008-12-23 05:57:34 +01:00
Marcel Holtmann
be2ffca847
Make internally used functions static
2008-12-23 04:35:02 +01:00
Marcel Holtmann
28cfb82c67
Declare variable before usage
2008-12-23 03:50:21 +01:00
Marcel Holtmann
66dcd1342d
Add braces around debug statement
2008-12-23 03:48:52 +01:00
Luiz Augusto von Dentz
e464fdc01d
Introduce sdp_copy_record.
...
To prevent use of sdp_gen_record_pdu + sdp_extract_pdu for copying
records.
2008-11-17 14:14:13 -03:00
Johan Hedberg
efcfad7c00
Get rid of format string warnings with recent gcc versions
...
Recent gcc versions, like 4.3.2 from ubuntu intrepid, give warnings like
"format not a string literal and no format arguments" without this
patch.
2008-10-20 01:10:11 +03:00
Marcel Holtmann
4e50b413d5
Include protocol UUIDs in the pattern otherwise complex searches fail
...
> ACL data: handle 11 flags 0x02 dlen 34
L2CAP(d): cid 0x0040 len 30 [psm 1]
SDP SSA Req: tid 0x6c len 0x19
pat uuid-16 0x110a (AudioSource) uuid-16 0x0100 (L2CAP) uuid-16 0x0019 (AVDTP)
max 100
aid(s) 0x0004 (ProtocolDescList) 0x0009 (BTProfileDescList) 0x0311 (SuppFeatures)
cont 00
< ACL data: handle 11 flags 0x02 dlen 14
L2CAP(d): cid 0x0040 len 10 [psm 1]
SDP SSA Rsp: tid 0x6c len 0x5
count 2
cont 00
Without this fix even searching for the L2CAP UUID fails.
2008-10-06 16:56:24 +02:00
Vinicius Costa Gomes
0477cf9b6c
Increases the size of the sdp pdu buffer and adds a sanity check for it
2008-09-10 19:32:41 -03:00
Marcel Holtmann
d39e08cc54
Convert SDP *_safe functions to default API
2008-08-06 02:02:03 +02:00
Marcel Holtmann
b8e5fea8d3
Move library source to lib directory
2008-07-26 18:45:23 +02:00