[fpc-pascal] TIniFile crash/memory loss
bartjunk64 at gmail.com
Thu Mar 31 18:52:26 CEST 2011
This however means that the programmer has to protect TIniFile.Free
with a Try..Except block, which is also rather unusual.
On 3/31/11, José Mejuto <joshyfun at gmail.com> wrote:
> Hello FPC-Pascal,
> Thursday, March 31, 2011, 5:05:35 PM, you wrote:
>>> Should I report this behaviour as a bug, or is it considered "by design"?
>>> (My old Delphi does not support the CacheUpdates property, so I cannot
>>> test how it behaves in Delphi)
> mvwb> Please report it as a bug. Your fix proposal is good.
> I think the fix is not good, eat an exception is not good at all, so I
> think better:
> destructor TIniFile.destroy;
> If FDirty and FCacheUpdates then
> inherited destroy;
> Silently not updating the file seems to be a no-no.
> Best regards,
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
More information about the fpc-pascal