Read From Socket Question

Björnke von Gierke bvg at mac.com
Sat Nov 19 08:15:06 EST 2011


Besides the typo in the last exapmple, it's kinda important to know what you actually send into the socket on the other side. is it another test code, or is it some existing software?

Is whatever is contained in the paramenter "myDevSock" actually in "the opensockets"? 

I suggest to make sure to check "the result" too, one never knows what might crop up there.

I haven't done any socket stuff recently, but i faintly remember having problems with EOF myself, but i don't remember what or why, only that i went with return as delimiter instead, and that worked much better.

On 18 Nov 2011, at 19:17, Warren Kuhl wrote:

> I am trying to retrieve data from a socket.
> 
> When I try:
> 
> read from socket myDevSock for xxxx characters
> put it into tData
> ...I get data
> 
> read from socket myDevSock until crlf
> put it into tData
> ...I get data
> 
> read from socket myDecSock until eof
> put it into tData
> ...no data
> 
> Wouldn't the read until eof pull in all data that is passed back?
> 
> Thanks for any help!
> Warren
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


-- 
Watch live presentations every Saturday:
http://livecode.tv

Use an alternative Dictionary viewer:
http://bjoernke.com/bvgdocu/

Chat with other RunRev developers:
http://bjoernke.com/chatrev/





More information about the use-livecode mailing list