Date: Sun, 11 Jun 2006 11:52:13 +0100 (BST) From: Iain Hibbert <plunky@rya-online.net> To: freebsd-bluetooth@freebsd.org Subject: SDP Message-ID: <1150023133.421908.1633.nullmailer@galant.ukfsn.org>
next in thread | raw e-mail | index | archive | help
Hi, in part of my work in Bluetooth for NetBSD* I just took the SDP implementation from FreeBSD direct to get a leg up and didnt look at it very much at first though I did make some changes, which basically comprised: 1. whitespace space-tab, whitespace at EOL, and empty line at EOF 2. lint errors and compiler warnings mostly warnings about casting and const which may not be errors in reality. I managed to remove all these though and now compile at WARNS=4 (for GCC3) 3. NetBSD does not have LOCAL_PEERCRED socket options, so I converted sdpd to use LOCAL_CREDS 4. I added something for Headset/Headset Audio Gateway profile. so what I have is still compatible at source level with FreeBSD. However, in adding the headset support I took a better look and I'm not sure I like the API exactly. I havent especially looked at the competing implementations, took a glance at the BlueZ one but they dont seem strong on documentation (and I didnt see any) and I'm hesitant to change the API as what we really dont need is yet another incompatible implementation. Some things I am uneasy with then: 1. sdp_open[_local]() may return a handle even though there is an error. Really, this is terrible! If there is an error in open, it should just return NULL and set errno accordingly. sdp_error() should not be necessary.. 2. to register a profile with the sdp daemon, the daemon itself must already know about the profile, even though its just a string of binary. It would be nice if a client program could just prepare this array and send it. 3. parsing results of an sdp query is annoyingly ugly, it would be nice if there was some lib function that could be used to extract values from the result in a generic way. So well, I'm not so sure if anybody else besides Max has done any work in this arena, but any input is good.. iain *latest archive is http://homepages.rya-online.net/plunky/netbt.32.tar.gz
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1150023133.421908.1633.nullmailer>