[fpc-pascal]Interesting Ansistring issues

Michael.VanCanneyt at Wisa.be Michael.VanCanneyt at Wisa.be
Thu Aug 16 12:40:26 CEST 2001


On Thu, 16 Aug 2001 BigMatt19 at aol.com wrote:

> Hey all,
>    Quick question... are there any known issues with reading an
> writing lots of ansistring in a record to and from a text file?
> Reason for the question is because I am trying to do just that...
> but for some reason after it makes a certain amount of reads and
> writes it gives me some majorly corrupt memory and gives me a
> runtime error 216 (GPF)

Sebastian Guenther reported something similar.

Can you send me some source code, then I will try to debug it;
Probably there is still some conversion error floating around
somewhere in the system unit ?

>
> My first thought was that it was my fault (lots of lines of code in this unit) so i went through it with a fine-tooth comb and every single file i opened is closed, every pointer i allocate is freed, etc.  The only thing is, since an Ansistring is a pointer... how do I free that memory?  Because none of the pointer routines seem to work on them. (Gives me type mismatches)
>
> Oh yeah.. i also went and downloaded the latest snapshot (1.1) and still no luck.
>
> Any ideas?

This will need some debugging, so some code that shows the problem would
be nice. Just writing a lot of output to the screen works fine here.

Michael.





More information about the fpc-pascal mailing list