Am 18.09.2013 23:34 schrieb "Marcos Douglas" <m...@delfire.net>:
>
> On Tue, Sep 17, 2013 at 2:41 PM, Sven Barth <pascaldra...@googlemail.com>
wrote:
> > On 17.09.2013 17:27, Marcos Douglas wrote:
> >>
> >> On Tue, Sep 17, 2013 at 12:18 PM, Marcos Douglas <m...@delfire.net>
wrote:
> >>>>
> >>>> Another thing you could try (just for testing): change your exception
> >>>> handler procedure to a function that returns bool and use it like
this:
> >>>>
> >>>> === code begin ===
> >>>>
> >>>>
> >>>> procedure TghSQLConnector.Connect;
> >>>> begin
> >>>>    try
> >>>>      FLib.Connect;
> >>>>    except
> >>>>      on E: Exception do
> >>>>        if not DoOnException(E) then
> >>>>          raise;
> >>>>    end;
> >>>> end;
> >>>>
> >>>> === code end ===
> >>>>
> >>>>
> >>>> Regards,
> >>>> Sven
> >>>
> >>>
> >>> The only difference is the use of raise; instead raise E; right?
> >>>
> >>> Marcos Douglas
> >>
> >>
> >> In project in attachment before, if you change the line 50
> >> from:
> >>      raise E;
> >>
> >> to:
> >>      raise Exception.Create(E.Message);
> >>
> >> Will work... but is this correct?
> >
> >
> > So this seems to be indeed a problem of freeing exceptions. Whether you
> > misuse the exception system or you encountered a bug needs to be
> > determined...
>
> If this is a bug I can register in bug tracker.

I don't know yet whether it's a bug or a mistake...

>
> >> Lazarus 1.1 r42461 FPC 2.6.2 i386-win32-win32/win64
> >
> >
> > Could you test your original one with 2.7.1 as well?
>
> I can't compile Lazarus with FPC 2.7.1 (as you saw in lazarus-list)
> so, I can't test...  :(

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.

Regards,
Sven
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to