August 31st, 2009, 09:45 AM
with the recvfrom() api call, it there a theoretical or physical limit to amount of data read from the socket?
does the tcp layer gurantee all data is reassembled and ordered correctly before being making the data available on the socket so that some application can read the data all at once?
In the following:
In the SOCK_STREAM case, what exactly does "message boundaries shall be ignored." mean?
The recvfrom() function shall return the length of the message written to the buffer pointed to by the buffer argument. For message-based sockets, such as [RS] [Option Start] SOCK_RAW, [Option End] SOCK_DGRAM, and SOCK_SEQPACKET, the entire message shall be read in a single operation. If a message is too long to fit in the supplied buffer, and MSG_PEEK is not set in the flags argument, the excess bytes shall be discarded. For stream-based sockets, such as SOCK_STREAM, message boundaries shall be ignored. In this case, data shall be returned to the user as soon as it becomes available, and no data shall be discarded.
Are there other technicalities to be considered when ready large data?
This is on linux/unix OS.
Last edited by Moore; August 31st, 2009 at 09:48 AM.
Reason: addition of OS details
Tags for this Thread
Click Here to Expand Forum to Full Width