Xref: utzoo comp.os.os2.programmer:587 comp.protocols.tcp-ip:15509 Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!cs.utexas.edu!uunet!panews.awdpa.ibm.com!ibmpa.awdpa.ibm.com!mikem From: mikem@ibmpa.awdpa.ibm.com Newsgroups: comp.os.os2.programmer,comp.protocols.tcp-ip Subject: Re: Problems with IBMs TCP/IP V1.1 for OS/2 Summary: send and recv() with BSD Stream sockets are not one to one Keywords: TCP/IP sockets stream send() recv() Message-ID: <1991Apr5.012707.29771@ibmpa.awdpa.ibm.com> Date: 5 Apr 91 01:27:07 GMT References: Sender: news@ibmpa.awdpa.ibm.com (news id) Reply-To: mikem@ibmpa.awdpa.ibm.com (Michael MacFaden) Organization: IBM M&S Development, Palo Alto Lines: 21 In article chlebosc@nadia.stgt.sub.org (Claudius Chlebosch) writes: >I got some problems with IBMs TCP/IP V1.1 for OS/2 using stream sockets an i >hope to get some help on this way. > >I have to write a program, which transfers data using stream sockets in portions >of 32 kByte. The sender should send this portions with one call to the send() >function and the receiver should get this portions with one call to the recv() >function. No. You can *not* code your client program to expect that a block of bytes sent by your server will arrive in a single receive. It doesn't matter what TCP/IP implementation you use. To do so is to cripple your client. What you need to do is place some sort of signature byte so that your client knows when the data block is complete and can process that block at that time. Michael R. MacFaden IBM Palo Alto Marketing Systems mikem@ibmpa.awdpa.ibm.com, macfaden@paloic1.vnet.ibm.com disclaimer: what I write above is not necessarily my employer's opinion