2007-02-28 12:23:00

by siddhant tewari

[permalink] [raw]
Subject: [Bluez-users] error while making call to ioctl for releasing a device

hi,
I am trying to obex push a file through rfcomm channel. Everything goes
fine (including sending of file) until i try to release the device via call
to ioctl

exact call is

ioctl(sock,RFCOMMRELEASEDEV,&req)

with error " Bad File Descriptor".

Can anyone give me a hint abt why can this happen..
Waiting for some reply

regards
siddhant


Attachments:
(No filename) (345.00 B)
(No filename) (431.00 B)
(No filename) (345.00 B)
(No filename) (164.00 B)
Download all attachments

2007-03-03 11:33:57

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] error while making call to ioctl for releasing a device

Hi Siddhant,

> I am trying to obex push a file through rfcomm channel. Everything
> goes fine (including sending of file) until i try to release the
> device via call to ioctl
>
> exact call is
>
> ioctl(sock,RFCOMMRELEASEDEV,&req)
>
> with error " Bad File Descriptor".
>
> Can anyone give me a hint abt why can this happen..
> Waiting for some reply

without looking at the code, I can't tell you anything. However you
should use the RFCOMM socket directly and not the virtual TTY. It is not
needed to put another kernel layer in between.

Regards

Marcel



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users