[Bluez-devel] Zero length L2CAP packets

Till Harbaum
2005-02-10T10:12:09Z

Hi,

while working on the avetana jsr82 implementation we discovered, that the bt
spec as well as jsr82 allow to transmit zero length l2cap packets. IMHO the
linux socket interface does not support zero length packets and a read
returning zero indicates an end of file (in this case meaning that the
connection has been closed).

What happens if the other side actually sends a zero length packet? Is this
dropped inside the kernel? Or will read return zero which i'll misinterpret
as the eof marker? How can i distinguish between eof and a zero length
packet?

Regards,
Till

--
Dr.-Ing. Till Harbaum Tel.: +49 721 4998963
BeeCon GmbH Fax: +49 721 4998962
Haid-und-Neu Strasse 7, 76131 Karlsruhe Mobil: +49 179 9087904
harbaum@beecon.de http://www.beecon.de