Re: OpenTransport behaviour under X
Re: OpenTransport behaviour under X
- Subject: Re: OpenTransport behaviour under X
- From: Lyndsey Ferguson <email@hidden>
- Date: Mon, 27 Oct 2003 10:27:18 -0500
First I would like to say that I'm still a newbie with OpenTransport and
Networking in general.
I thought that OTLook was to poll for data event or to find out what failed
in the case of an kOTLookErr and clear the endpoint for more usage.
So, as I understand it, you don't have to call OTLook; you can continue to
call OTRcv until you have no more data. Correct?
You can check the T_MORE flag parameter to see if there is more data ready
to be collected.
Lyndsey
On 10/27/03 8:50 AM, "Marc Stibane" <email@hidden> wrote:
>
Since no one answered my question (with the subject "sockets in
>
Powerplant") I repost it here under a better subject title:
>
>
> News - now it broadcasts (UDP), and gets an answer back.
>
>
>
> Under MacOS X you cannot broadcast to 255.255.255.255.
>
> You have to broadcast to your own subnet, in my case to 192.168.102.255.
>
>
>
> OK, so now I find my RIP and therefor its IP address.
>
> But then the (TCP) connect times out - no connection. There must be
>
> another gotcha in the OpenTransport glue.
>
>
Got it.
>
The code (synchronous, blocking) attempts to read 4 bytes - one after the
>
other. So it checks with OTLook whether there is data (yes), then asks
>
how much with OTCountDataBytes (8 bytes), then reads ONE byte with OTRcv,
>
and then again asks with OTLook whether there is data (no, BUMMER).
>
>
This worked under MacOS 9 - it seems under X you have to read the whole
>
buffer until you can ask again...
>
>
Is this the intended behaviour? If so where is it documented?
>
>
Do I have to change this read logic (the network code is shared with
>
MacOS 9 and Windows, and works there, so I would like to not change it if
>
possible) or is there anything I can do to get OTLook to answer T_Data
>
when there is still unread data in the buffer?
>
>
>
>
Marc Stibane
>
Fesh! email@hidden
>
Kurf|rstenstr. 154 tel +49-30-3990 2690
>
10785 Berlin, Germany mobil +49-173-6522 422
>
>
>
In a world without walls and fences,
>
who needs windows and gates?
>
_______________________________________________
>
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.
>
--
Lyndsey D. Ferguson
Software Engineer
Nemetschek N.A., Inc.
email@hidden
--
_______________________________________________
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.