Re (2): OTBind + Serial Endpoint
Re (2): OTBind + Serial Endpoint
- Subject: Re (2): OTBind + Serial Endpoint
- From: Jiri Volejnik <email@hidden>
- Date: Tue, 27 Aug 2002 12:18:52 +0200
>
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).
But what address buffer size other than 0 should I use, when there is no
address structure specified for Serial Endpoints? I tried several casual
sizes, but with no success.
>
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.
This is what I was trying the first time, but it gives the same error.
Thanks again,
Jiri.
_______________________________________________
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.