Article View: borland.public.cppbuilder.internet.socket
Article #5365Re: Problem with sending data with TCS/TSS (data has been received mixed and/or damaged)
From: Vladimir Stefanovic
Date: Fri, 20 Aug 2004 18:57
Date: Fri, 20 Aug 2004 18:57
23 lines
1708 bytes
1708 bytes
Hi,
Yes, thanks... That's it.
I'm too tired these days to see the obvious solutions.
> if( Stream->WaitForData (5000) )
> {
> int size = 0;
> if( !ReadData(Stream, &size, sizeof(int)) )
> break;
>
> char *buffer = new char[size];
> try
> {
> if( ReadData(Stream, buffer, size) )
> // use your buffered data as needed...
> }
Best regards,
Vladimir Stefanovic
Technical Details
Message-ID:
<412649df$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<41245031$1@newsgroups.borland.com> <4124d7ab@newsgroups.borland.com> <4124f2ca@newsgroups.borland.com> <4125baa0$1@newsgroups.borland.com> <41260071@newsgroups.borland.com> <4126422a$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,9d2d5d657ea2710a X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Vladimir Stefanovic" <spam@not.needed> Newsgroups: borland.public.cppbuilder.internet.socket References: <41245031$1@newsgroups.borland.com> <4124d7ab@newsgroups.borland.com> <4124f2ca@newsgroups.borland.com> <4125baa0$1@newsgroups.borland.com> <41260071@newsgroups.borland.com> <4126422a$1@newsgroups.borland.com> Subject: Re: Problem with sending data with TCS/TSS (data has been received mixed and/or damaged) Date: Fri, 20 Aug 2004 20:57:22 +0200 Lines: 26 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2314.1300 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 NNTP-Posting-Host: 213.137.116.170 Message-ID: <412649df$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1093028319 213.137.116.170 (20 Aug 2004 11:58:39 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail