> > > Not when you stick to the API. OTOH, when BtOBEX_TransportConnect()
>  > > returns with -1, you can ask "errno", don't you?
>  > >  I must admit, though, that the API lacks there.
>  >
>  > Can I ask for a more specific error no? I dont see an API function to do
>  > that.
>
>
> see connect(3) manpage

>
>  > As a -1 return  from BtOBEX_TransportConnect() does not tell me if the
>  > connection was:
>  >
>  > Refused by server,
>
>
> if (errno == ECONNREFUSED)
>
>  > Timed out,
>
>  if (errno == ETIMEDOUT)
>
>  > General connection error
>
>  Anything else. However, I just see that this will not work as another system
>  call is done before the function returns to the user :-(
>  I created and attached an untested patch that creates a new API function
>   int OBEX_GetLastError(obex_t*)
>  that returns the last errno value (see above) and sets that value for
>  BtOBEX_TransportConnect case.
>

Great!

Sorry to ask a silly question but I am quite new to linux and have no
idea how to apply this patch!! What do i need to do?

Also how do I see connect(3) manpage?

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Openobex-users mailing list
[email protected]
http://lists.sourceforge.net/lists/listinfo/openobex-users

Reply via email to