Recent

Author Topic: IDE freezes on SelectDirectory  (Read 311 times)

Roman

  • New Member
  • *
  • Posts: 23
IDE freezes on SelectDirectory
« on: January 24, 2023, 09:04:57 am »
I created a program with:
 
Code: Pascal  [Select][+][-]
  1. SelectDirectory('Select folder','D:\',folderName);
The compiled program works fine, but running it from IDE the IDE freezes. Is it a bug or I missed something?

I am using: Windows 10 home 22H2
Lazarus 2.2.4 (rev lazarus_2_2_4) FPC 3.2.2 x86_64-win64-win32/win64
installed from lazarus-2.2.4-fpc-3.2.2-win64.exe 

Handoko

  • Hero Member
  • *****
  • Posts: 4764
  • My goal: build my own game engine using Lazarus
Re: IDE freezes on SelectDirectory
« Reply #1 on: January 24, 2023, 11:07:05 am »
Maybe that caused by antivirus, try to disable your antivirus or Microsoft Defender to see what happens.

wp

  • Hero Member
  • *****
  • Posts: 10464
Re: IDE freezes on SelectDirectory
« Reply #2 on: January 24, 2023, 11:15:29 am »
Use FPDebug rather than GDB ("Tools" > "Options" > "Debugger" > "Debugger Backend" > select "FpDebug internal Dwarf-Debugger" in the top comobox).

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 8609
  • Debugger - SynEdit - and more
    • wiki
Re: IDE freezes on SelectDirectory
« Reply #3 on: January 24, 2023, 11:22:08 am »
There was a very similar thread recently (with open file or open dir dialog / though I believe Win11).

It turned out to be a bug in the FpDebug in 2.2.4.

If you are affected by the same issue, then you have 2 options:

1) Use Lazarus 2.3 (git main branch)
2) Use the gdb based debugger (Tools > Options > Debugger > Debugger Backend)
   If using gdb, ensure not to use "Dwarf 3", instead use "Dwarf with sets"
« Last Edit: January 24, 2023, 11:23:51 am by Martin_fr »

Roman

  • New Member
  • *
  • Posts: 23
Re: IDE freezes on SelectDirectory
« Reply #4 on: January 24, 2023, 12:09:24 pm »
Thank you all. I have changed "Debugger Backend" from "FpDebug internal Dwarf-Debugger" to "GNU debugger" and it helped. It seems that SelectDirectory is now a bit slower than before, but it works.
« Last Edit: January 24, 2023, 12:11:23 pm by Roman »

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 8609
  • Debugger - SynEdit - and more
    • wiki
Re: IDE freezes on SelectDirectory
« Reply #5 on: January 24, 2023, 12:15:00 pm »
It seems that SelectDirectory is now a bit slower than before, but it works.

If you don't have any dll into which you need to debug:
Set the option "DisableLoadSymbolsForLibraries"

See "Lazarus 1.2.4 and higher" on https://wiki.lazarus.freepascal.org/GDB_Debugger_Tips#gdb.exe_has_stopped_working_.2F_SigSegv_with_Open.2FClose_Dlg


 

TinyPortal © 2005-2018