Invalid Pointer Operation with Builtin driver

Discussion of open issues, suggestions and bugs regarding usage of dbExpress drivers for InterBase & Firebird in Delphi and C++Builder
Post Reply
Wade
Posts: 31
Joined: Sun 03 Jan 2010 06:04

Invalid Pointer Operation with Builtin driver

Post by Wade » Sun 03 Jan 2010 23:19

Delphi 2009
FB 2.1
DbxIda 2.50.20

On a form, if I run this code:

procedure TForm1.Button2Click(Sender: TObject);
var
C: TSQLConnection;
begin
C := TSQLConnection.Create(self);
try
C.DriverName := DbxIdaDriverLoader.sBuiltinDriverName;
//C.DriverName := DBXDevArtInterbase.sDriverName;

C.VendorLib := 'C:\Program Files\Firebird\Firebird_2_1\bin\FBClient.dll';
C.LoginPrompt := False;
C.Params.Clear;
C.Params.Add('User_Name=SYSDBA');
C.Params.Add('Password=masterkey');
C.Params.Add('Database=' + 'localhost:C:\MyDatabase.fdb');
C.Open;
finally
C.Free;
end;

Application.Terminate;
end;

Then I get an Invalid Pointer Operation error when the app is closing.

The error occurs in TDBXDynalinkDriver.Destroy;

If I change the code to use

C.DriverName := DBXDevArtInterbase.sDriverName;

instead of

C.DriverName := DbxIdaDriverLoader.sBuiltinDriverName;

then the error does not occur.

Is this a regression in 2.50.XX ? I did not see it in 2.40.16

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Fri 15 Jan 2010 09:07

We have fixed this problem. The fix will be included in the next build of DbxIda.

To fix the problem, remove the following line

Code: Select all

  SQLDriver.Free;
from the finalization section in dbxibc.pas.

Post Reply