[fpc-devel]fcl, classes unit, memory issue
rimga at ktl.mii.lt
Tue Apr 20 15:58:12 CEST 2004
----- Original Message -----
From: "Michael Van Canneyt" <michael.vancanneyt at wisa.be>
To: <fpc-devel at lists.freepascal.org>
Sent: Monday, April 19, 2004 11:23 AM
Subject: Re: [fpc-devel]fcl, classes unit, memory issue
> On Sun, 18 Apr 2004, Rimgaudas Laucius wrote:
> > Hello,
> > uses
> > classes;
> > var
> > l: tstringlist;
> > begin
> > l.loadfromfile('file.txt'); //<-hangs here
> > ...
> > end.
> > Program hangs (under windows, 1.9.2 and earlier v.) then i try to load
relatively large file (~7 MB) without raising any error message. It works
ok, if i set more memory using directive ($M). Why do not program allocate
neaded memory automaticaly? Do i need to calculate how much memory need to
program and set its size before compilation always?
> No. Are you sure it hangs ? My guess is that it is simply working very
> hard. It only allocates a 1K buffer to load the file, so that should not
> be the issue.
Yes i am sure. I registered it as issue 3059 with "working" example.
> fpc-devel maillist - fpc-devel at lists.freepascal.org
More information about the fpc-devel