<p>Am 18.09.2013 23:34 schrieb "Marcos Douglas" <<a href="mailto:md@delfire.net">md@delfire.net</a>>:<br>
><br>
> On Tue, Sep 17, 2013 at 2:41 PM, Sven Barth <<a href="mailto:pascaldragon@googlemail.com">pascaldragon@googlemail.com</a>> wrote:<br>
> > On 17.09.2013 17:27, Marcos Douglas wrote:<br>
> >><br>
> >> On Tue, Sep 17, 2013 at 12:18 PM, Marcos Douglas <<a href="mailto:md@delfire.net">md@delfire.net</a>> wrote:<br>
> >>>><br>
> >>>> Another thing you could try (just for testing): change your exception<br>
> >>>> handler procedure to a function that returns bool and use it like this:<br>
> >>>><br>
> >>>> === code begin ===<br>
> >>>><br>
> >>>><br>
> >>>> procedure TghSQLConnector.Connect;<br>
> >>>> begin<br>
> >>>> try<br>
> >>>> FLib.Connect;<br>
> >>>> except<br>
> >>>> on E: Exception do<br>
> >>>> if not DoOnException(E) then<br>
> >>>> raise;<br>
> >>>> end;<br>
> >>>> end;<br>
> >>>><br>
> >>>> === code end ===<br>
> >>>><br>
> >>>><br>
> >>>> Regards,<br>
> >>>> Sven<br>
> >>><br>
> >>><br>
> >>> The only difference is the use of raise; instead raise E; right?<br>
> >>><br>
> >>> Marcos Douglas<br>
> >><br>
> >><br>
> >> In project in attachment before, if you change the line 50<br>
> >> from:<br>
> >> raise E;<br>
> >><br>
> >> to:<br>
> >> raise Exception.Create(E.Message);<br>
> >><br>
> >> Will work... but is this correct?<br>
> ><br>
> ><br>
> > So this seems to be indeed a problem of freeing exceptions. Whether you<br>
> > misuse the exception system or you encountered a bug needs to be<br>
> > determined...<br>
><br>
> If this is a bug I can register in bug tracker.</p>
<p>I don't know yet whether it's a bug or a mistake...</p>
<p>><br>
> >> Lazarus 1.1 r42461 FPC 2.6.2 i386-win32-win32/win64<br>
> ><br>
> ><br>
> > Could you test your original one with 2.7.1 as well?<br>
><br>
> I can't compile Lazarus with FPC 2.7.1 (as you saw in lazarus-list)<br>
> so, I can't test... :(</p>
<p>It's ok if you use a 2.7.1 before the merge of the cpstrrtl branch. There AFAIK weren't any exception related changes since then.</p>
<p>Regards,<br>
Sven</p>