Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

Freepascal 3.2.0 release candidate (Announce)

posted by Laaca Homepage, Czech republic, 29.04.2020, 23:03

Interresting.
I've tracked the problem and the code with caused this behaviour was in my include file DEFINES.INC which is called from all my units.
And there is this line: {$IFDEF DEBUG}{$CHECKPOINTER ON}{$ENDIF}

But I've never selected the option "-gh"

The Freepascal help for the {$CHECKPOINTER} says this:

"The {$CHECKPOINTER} directive turns heap pointer checking on (value ON) or off (value OFF). If heap pointer checking is on and the code is compiled with the -gh (heaptrace) option on, then a check is inserted when dereferencing a pointer. The check will verify that the pointer contains a valid value, i.e. points to a location that is reachable by the program: the stack or a location in the heap. If not, a run-time error 216 or 204 is raised.

If the code is compiled without -gh switch, then this directive has no effect. Note that this considerably slows down the code."



1) From the text above does not follow that the tracking of the unfreed memory blocks should be on. (especially when no "-gh" switch is set)

2) The FPC 3.2.0 behaviour is different from FPC 3.0.4 so the first or the latter does it wrong.

---
DOS-u-akbar!

 

Complete thread:

Back to the forum
Board view  Mix view
22632 Postings in 2109 Threads, 402 registered users, 409 users online (0 registered, 409 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum