On Wed, May 18, 2011 at 3:45 PM, Leonardo M. Ramé <l.r...@griensu.com> wrote: > > Hi, I wrote a simple console application with widgetype NoGui to > test a connection to Firebird 2.5 on FreeBsd. When I run in the console, > it hangs when the method TIBConnection.Connected := True > is called (isc_attach_database). I don't get any error message, it just hangs > until I press ctrl+c. > > The conflict is between "interfaces" unit and FreeBSD on a headless > machine (without graphical user interface). > > Here's the program: > > program test; > > {$mode objfpc}{$H+} > > uses > interfaces, > fpCGI, > IBConnection; > > {$R *.res} > > var > FIbConnection: TIBConnection; > SQLTransaction1: TSQLTransaction; > > begin > FIbConnection := TIBConnection.Create(nil); > SQLTransaction1 := TSQLTransaction.Create(nil); > FIbConnection.Connected := False; > FIbConnection.DatabaseName := 'test'; > FIbConnection.UserName := 'SYSDBA'; > FIbConnection.Password := 'masterkey'; > FIbConnection.HostName := '127.0.0.1'; > FIbConnection.LoginPrompt := False; > > writeln('--- Here the program freezes ---'); > FIbConnection.Connected := True; > SQLTransaction1.Free; > FIbConnection.Free; > end. > > If I compile the program with "fpc test.pas" commenting out the > interfaces unit, it works ok. > > My setup is this: > > Freebsd 8.2 - amd64 - without X. > Lazarus 0.9.31 - SVN Revision: 30780 > FPC 2.5.1 - SVN Revision: 17494
Why use NoGui in this example? Marcos Douglas -- _______________________________________________ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus