Alper Albayrak wrote: > Yes, Im using TCP. > I solved my problem (at least in here) with replacing Move() into > CopyMemory() > > I'm using LineMode, to receive all data sent. (My data size is 49b in > total and no string data in it)
That is dangerous! Are you able to exclude that the LineEnd bytes will never be found in your binary data? I don't think so. ICS v7 contains a demo that shows one way to send binary data mixed with string data: http://svn.overbyte.be:8443/svn/ics/branches/icsv7/Delphi/Internet/OverbyteIcsBinCliDemo1.pas (http://wiki.overbyte.be/wiki/index.php/FAQ#How_to_get_ICS) > Are there any conflicts i may encounter in the approach stated below? > (I intend to replace Rcvd variable with a global one to prevent having > allocating it in every receive) A global buffer is the way to go. Do not use PChar for binary data but either TBytes, PByte or PAnsiChar, that makes it easier to convert the code to support Unicode later on. -- Arno Garrels -- To unsubscribe or change your settings for TWSocket mailing list please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
