Re: OTBind + Serial Endpoint
Re: OTBind + Serial Endpoint
- Subject: Re: OTBind + Serial Endpoint
- From: Quinn <email@hidden>
- Date: Tue, 27 Aug 2002 10:56:42 +0100
At 11:40 +0200 27/8/02, Jiri Volejnik wrote:
I'm writing simple serial port wrapper under Carbon (therefore using OT),
and have a problem with OTBind. It returns kOTBadAddressErr, even thought
Serial Endpoints don't use the address.
Anyone can see the reason?
This is because you haven't initialised the len field bind.addr.
When dealing with TNetbuf, you have to initialise len and buf for
input parameters (such as the second parameter to OTBind), and maxlen
and buf for output parameters (such as the third parameter to OTBind).
However, for OTBind there's an easier way. When binding serial
endpoints (and indeed any outgoing connections), just pass NULL to
both the second and third parameters.
S+E
--
Quinn "The Eskimo!" <
http://www.apple.com/developer/>
Apple Developer Technical Support * Networking, Communications, Hardware
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.