Am 13.10.2016 10:09 schrieb "Graeme Geldenhuys" < mailingli...@geldenhuys.co.uk>: > > On 2016-10-12 20:37, grouchysmurf wrote: > > Say, I have a code, where TH is a Class(TCustomApplication): > > > > ph := TH.Create(Nil); > > ph.Initialize; > > ph.ProcessOptions; > > ph.Run; > > ph.Free; > > I would also rewrite that with a try..finally as in: > > ph := TH.Create(nil) > try > ph.Initialize; > ph.ProcessOptions; > ph.Run; > finally > ph.Free; > end; >
That won't help with Halt() however as that will "jump" directly to the unit finalization, ignoring any and all exception handlers along the way. Regards, Sven
_______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal