Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2001-10

Postgres on Win32

7 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Vit Kavan

Hi all,

(OK maybe mostly Michael :-))

I've spent hours trying to make Postgres unit working on Win32 (using the pq.dll from cygwin contributions). I even made the from-scratch-miniport, but still all I get is RE 216 (Access Violation) on pqSetDBLogin and it's the same problem when I compile the program by Delphi5. Any ideas? Could it be some calling conventions problem?

Thanks, Vitek

PS.:
The library itself works, because I'm able to connect to the remote Linux/Postgres server with psql.exe.

______________________________________________________________________ Objevte oranzovy svet financi a vyhrajte v soutezi s ING! http://soutez.ing.cz

Unknown author
to Vit Kavan
Show quoted text 10 lines
Hi all, (OK maybe mostly Michael :-)) I've spent hours trying to make Postgres unit working on Win32 (using the pq.dll from cygwin contributions). I even made the from-scratch-miniport, but still all I get is RE 216 (Access Violation) on pqSetDBLogin and it's the same problem when I compile the program by Delphi5. Any ideas? Could it be some calling conventions problem?

Send me what you have, and I'll have a try.

Michael.

Michael Van Canneyt
to Vit Kavan
Vit Kavan wrote 7 lines
Hi, here comes the source of the mini-unit and the crashing test program (both FPC and Delphi5). If you want the DLLs I used, get them at http://www.volny.cz/vtech/pgdll.zip (cca 250KB).

try changing the 'cdecl' with 'stdcall'; Windows libraries use the stdcall convention instead of cdecl.

I can't test it myself since I have no running postgresql server to test with.

Michael.

Vit Kavan

I tried 'stdcall' already and it's the same :-(

Show quoted text 25 lines
On Wed, 17 Oct 2001, Vit Kavan wrote: > Hi, > > here comes the source of the mini-unit and the crashing test program (both > FPC and Delphi5). > > If you want the DLLs I used, get them at http://www.volny.cz/vtech/pgdll.zip > (cca 250KB). try changing the 'cdecl' with 'stdcall'; Windows libraries use the stdcall convention instead of cdecl. I can't test it myself since I have no running postgresql server to test with. Michael. _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

______________________________________________________________________ Nejenom anglicko-cesky slovnik: http://slovnik.seznam.cz