🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: i need ideas/comments with tclientsocket

#3274
From: Remy Lebeau (TeamB)
Date: Tue, 01 Nov 2005 17:11
22 lines
1999 bytes
"Hans Galema" <notused@notused.nl> wrote in message
news:4367395a@newsgroups.borland.com...

> Well I have to. But you did not know why

As I said before, the Size property already checks the capacity of the
currently allocated Memory and then reallocates the Memory only when
actually needed.  TMemoryStream has a Capacity property tha indicates the
size of the allocated memory.  That is different than the Size property,
which specifies the number of bytes that are available in the allocated
Memory.  Setting the Size also sets the Capacity, which may be more than the
Size.

> I never size the stream down.

If you don't do that, then the stream will slowly continue allocating more
and more memory until it runs out.  You should reduce the Size periodically
to reduce the amount of unused memory.


Gambit
Technical Details
Message-ID: <4367a1c5$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news2.volia.net!news.germany.com!newsfeed.freenet.de!newsfeed.inode.at!reader.uucp.at!feeder02.uucp.at!newsfeed.uucp.at!news.uucp.at!newsgroups.borland.com!not-for-mail
References: <43662baf$1@newsgroups.borland.com> <43664511@newsgroups.borland.com> <4366672a$1@newsgroups.borland.com> <43668460@newsgroups.borland.com> <4366d220$1@newsgroups.borland.com> <43672a80$1@newsgroups.borland.com> <43673233$1@newsgroups.borland.com> <4367395a@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,5c33b8c6a9ca7fdb
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.internet.socket
References: <43662baf$1@newsgroups.borland.com> <43664511@newsgroups.borland.com> <4366672a$1@newsgroups.borland.com> <43668460@newsgroups.borland.com> <4366d220$1@newsgroups.borland.com> <43672a80$1@newsgroups.borland.com> <43673233$1@newsgroups.borland.com> <4367395a@newsgroups.borland.com>
Subject: Re: i need ideas/comments  with tclientsocket
Date: Tue, 1 Nov 2005 09:11:39 -0800
Lines: 24
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <4367a1c5$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1130865093 68.69.17.41 (1 Nov 2005 09:11:33 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news2.volia.net!news.germany.com!newsfeed.freenet.de!newsfeed.inode.at!reader.uucp.at!feeder02.uucp.at!newsfeed.uucp.at!news.uucp.at!newsgroups.borland.com!not-for-mail