[fpc-pascal] SIGSEGV in SYSTEM_TOBJECT_$__CLEANUPINSTANCE when calling from C app

Matthias Klumpp matthias at nlinux.org
Mon Dec 13 22:43:16 CET 2010


On Mon, 13 Dec 2010 22:34:38 +0200, Juha Manninen
<juha.manninen62 at gmail.com> wrote:
> Matthias Klumpp kirjoitti maanantai 13 joulukuu 2010 18:50:46:
>>  if obj^ = nil then exit;
>>  FreeAndNil(obj^);
> 
> Shouldn't it be:
> 
>  // if obj = nil then exit;  <-- not really needed
>  FreeAndNil(obj);
Yes, right. The first line was only for testing. But removing the line, of
course, does not affect the behavior in any way, which means the error is
still present.
Regards
  Matthias




More information about the fpc-pascal mailing list