🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #5750

Re : Image and network problem - the answer !

#5750
From: Patrick FAURE
Date: Sat, 19 Jun 2004 05:02
17 lines
1271 bytes
Hi,

I found the solution.
The problem was in :
Socket->ReceiveBuf(OFFSETBYTES(DataComplete->Memory, oldSize),
    incomingSize);
where the number of bytes read by ReceiveBuf is not always
 equal to incomingSize.
Here is the solution :
int readBytes = Socket->ReceiveBuf(OFFSETBYTES(DataComplete->
Memory, oldSize), incomingSize);
DataComplete->Size = oldSize + readBytes;
So there is no hole in received data stream.
My image appears correctly in TImage.

Patrick
Technical Details
Message-ID: <40d3c8ef$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11508e,bc9967afc75004ef,start
X-Google-Attributes: gid11508e,public
From: "Patrick FAURE" <DidactSoft@aol.com>
Sender: "Patrick FAURE" <DidactSoft@aol.com>
Reply-To: "Patrick FAURE" <DidactSoft@aol.com>
Subject: Re : Image and network problem - the answer ! 
Newsgroups: borland.public.cppbuilder.internet.socket
X-User-Info: 172.210.68.222     
NNTP-Posting-Host: 207.105.83.66
Message-ID: <40d3c8ef$1@newsgroups.borland.com>
Date: 18 Jun 2004 22:02:39 -0700
X-Trace: newsgroups.borland.com 1087621359 207.105.83.66 (18 Jun 2004 22:02:39 -0700)
Lines: 17
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail