problem with thread lazarus / 8-Other ---------------------------------------------------------------------- guest · 2005-10-14 23:19 My application crashes when I call GetProxy.Terminate; Can someone explain what is wrong ? Code: [Select] type   TProxyThread = class(TThread)   private   protected    procedure Show;    procedure Execute; override;   public    constructor Create;   end;   { TForm1 }   TForm1 = class(TForm)     ApplicationProperties1: TApplicationProperties;     btLoad: TButton;     Button1: TButton;     GroupBox1: TGroupBox;     edProxyList: TLabeledEdit;     edOpenURL: TLabeledEdit;     tvProxyList: TTreeView;     procedure Button1Click(Sender: TObject);     procedure btLoadClick(Sender: TObject);   private     { private declarations }     GetProxy : TProxyThread;   public     { public declarations }   end; var   Form1: TForm1; implementation { TForm1 } constructor TProxyThread.Create; begin   FreeOnTerminate := true;   inherited Create(false); end; procedure TProxyThread.Show; begin  Form1.Caption := Form1.Caption+'.'; end; procedure TProxyThread.Execute; begin  while not Terminated do  begin   sleep(500);   Synchronize(Show);  end; end; procedure TForm1.btLoadClick(Sender: TObject); begin  GetProxy := TProxyThread.Create; end; procedure TForm1.Button1Click(Sender: TObject); begin  GetProxy.Terminate; end; ---------------------------------------------------------------------- Marc · 2005-10-17 12:43 Do you get the dots in your caption ? (IE. does the thread run ?) ---------------------------------------------------------------------- Anonymous · 2005-10-17 15:25 Yes, thread is running without problem, but my application crashes when I click on Button1 ---------------------------------------------------------------------- Anonymous · 2005-10-17 19:45 [SOLVED] it was a problem with FPC 2.0.1 (2005/10/02) (installed with Lazarus-0.9.10-20051002-win32).  I just change to FPC 2.0.0 (2005/05/08) and it's works fine. Thx for all.