Recent

Author Topic: Lazarus crashes  (Read 4898 times)

mj

  • Newbie
  • Posts: 4
Lazarus crashes
« on: October 10, 2016, 03:44:42 pm »
Lazarus often crashes on my computer. Usually it happens when I search with control-F. It also crashes sometimes when I switch tabs, type a variable name, or scroll up/down. The message it gives me is:
Access Violation

Press OK to ignore and risk data corruption
Press Cancel to kill the program


This is on windows 7 with Lazarus v. 1.6 64bit.
I have tried verifying the integrity of the installer and did a clean reinstall. Is there a crash dump file I can find that might have more information?




Bart

  • Hero Member
  • *****
  • Posts: 5290
    • Bart en Mariska's Webstek
Re: Lazarus crashes
« Reply #1 on: October 10, 2016, 03:57:27 pm »
Start Lazarus with --debug-log=path\to\debug-log.txt
Alternatively start Lazarus from within the debugger (gdb), let it crash then inside the debugger type "bt" (wihtout the quotes) to get a backtrace.

For both solutions Lazarus must be build with debug info.

Bart

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #2 on: November 13, 2020, 11:21:49 am »
Hi

I also encounter some crashes, but on MacOS how to add the --debug-log parameter?
Conscience is the debugger of the mind

dbannon

  • Hero Member
  • *****
  • Posts: 2796
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Lazarus crashes
« Reply #3 on: November 13, 2020, 12:03:43 pm »
This is on windows 7 with Lazarus v. 1.6 64bit.

v1.6 is quite old, its very likely that what ever is worrying you has been fixed since then. And I think there is little chance of anyone fixing 1.6 if you do manage to track down the problem.

Is the a reason you are using v1.6 and not the current v2.0.10  ?

Davo
Lazarus 3, Linux (and reluctantly Win10/11, OSX Monterey)
My Project - https://github.com/tomboy-notes/tomboy-ng and my github - https://github.com/davidbannon

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #4 on: November 13, 2020, 04:11:00 pm »
I am using 2.0.10.
Conscience is the debugger of the mind

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Lazarus crashes
« Reply #5 on: November 13, 2020, 06:02:10 pm »
I am using 2.0.10.
when it crashes does macOS offer you an error dump?
if yes, could you please provide a copy of it?

Handoko

  • Hero Member
  • *****
  • Posts: 5154
  • My goal: build my own game engine using Lazarus
Re: Lazarus crashes
« Reply #6 on: November 13, 2020, 06:22:26 pm »
Many suggestions already given. I'll give you different direction.

I am a computer technician. For your case I suggest you to download some free 3D games and play them for several hours. If it does not crash then it passes.

For further test, you can search the Internet and download a free tool called computer stress test. If it passes all the tests then your computer is okay.

Why does a computer crash? There are many possibilities. The hardware, the VGA/GPU, the Windows, the drivers, infected by virus/malware, the bug in the program itself.

Lazarus is not bug free. But Lazarus 1.6 wasn't that bad. It doesn't crash once every several days. My Lazarus IDE never crash, not even once, unless I use it to run ugly code so the debugger crashes.
« Last Edit: November 13, 2020, 06:34:12 pm by Handoko »

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #7 on: November 13, 2020, 10:46:14 pm »
when it crashes does macOS offer you an error dump?
if yes, could you please provide a copy of it?

Well no, I have the dialog box saying:
Quote
Press OK to ignore and risk data corruption
Press Cancel to kill the program

The thing is on MacOS, I don't run LazPaint from the command line, it is an app. Hence my question: how to add the --debug-log parameter?
Conscience is the debugger of the mind

JuhaManninen

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4468
  • I like bugs.
Re: Lazarus crashes
« Reply #8 on: November 13, 2020, 11:18:41 pm »
Lazarus often crashes on my computer. Usually it happens when I search with control-F ...
There is some bug lurking under the search / replace stuff but nobody could reproduce it properly.
 https://bugs.freepascal.org/view.php?id=29925
However it does not explain your other crashes.
Mostly Lazarus trunk and FPC 3.2 on Manjaro Linux 64-bit.

dbannon

  • Hero Member
  • *****
  • Posts: 2796
    • tomboy-ng, a rewrite of the classic Tomboy
Re: Lazarus crashes
« Reply #9 on: November 13, 2020, 11:34:37 pm »

The thing is on MacOS, I don't run LazPaint from the command line, it is an app. Hence my question: how to add the --debug-log parameter?

You can start it from the command line, you have to use the app bundle as a binary name. I tell my users to get a debug log of tomboy-ng like this -

Code: [Select]
open /Applications/tomboy-ng.app --args     "--debug-log=$HOME/tomboy-ng.log"  "--debug-sync"
You can probably directly edit the app bundle too, its just a directory. try google ...

Davo
Lazarus 3, Linux (and reluctantly Win10/11, OSX Monterey)
My Project - https://github.com/tomboy-notes/tomboy-ng and my github - https://github.com/davidbannon

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #10 on: November 14, 2020, 05:16:09 pm »
Ok thanks. So I have made a script with Script Editor and then exported it as Lazarus-debug.app in the Applications folder. Works fine. Here is the code:

Code: AppleScript  [Select][+][-]
  1. do shell script "open -a /Applications/Lazarus.app --args \"--debug-log=$HOME/lazarus.log\" \"--debug-sync\""

Next time it crashes I will be ready.  :)
Conscience is the debugger of the mind

MarkMLl

  • Hero Member
  • *****
  • Posts: 6686
Re: Lazarus crashes
« Reply #11 on: November 14, 2020, 06:02:30 pm »
Next time it crashes I will be ready.  :)

Try to catch it more than once, if it really is a software problem I'd expect the failure to be consistent.

I agree with what others are saying: by and large the IDE is robust, and I certainly use ^F searches enough to notice any problem.

/However/, I'm typically running on Linux and there's always a possibility that your installation has something unusual in it... odd keyboard handler or something like that.

In fact it reminds me of something that I used to see with one particular version of Delphi if run under Qemu virtualisation: so a "Search files" and it would crash the emulator.

So if people do appear to be sceptical, you need to try to work out what you've got that's unusual.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #12 on: November 14, 2020, 06:04:08 pm »
It's not crashing when searching. I don't even remember when. Just that when it happens, the message does not help much.
Conscience is the debugger of the mind

MarkMLl

  • Hero Member
  • *****
  • Posts: 6686
Re: Lazarus crashes
« Reply #13 on: November 14, 2020, 06:38:36 pm »
It's not crashing when searching. I don't even remember when. Just that when it happens, the message does not help much.

In OP's case, it was crashing when searching. You've hijacked his thread :-)

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

circular

  • Hero Member
  • *****
  • Posts: 4220
    • Personal webpage
Re: Lazarus crashes
« Reply #14 on: November 14, 2020, 06:41:30 pm »
Sort of. But the title is generic and that was the first and main search result.
Conscience is the debugger of the mind

 

TinyPortal © 2005-2018