Recent

Author Topic: External: SIGSEGV  (Read 581 times)

RogerHJB

  • New member
  • *
  • Posts: 6
External: SIGSEGV
« on: December 30, 2022, 09:25:19 pm »
I am using Lazarus 2.2.4, FPC 3.2.2 on X86-64-linux-gtk2

Every time I try to change the caption on any object, I have tried TEdit, TStaticText and TButton, I get a External: SIGSEGV.  I can change the colour with no problem but if I try  other properties such as top, width, left, etc, I get the same error.

Objects are located on a TForm.

Roger
« Last Edit: December 30, 2022, 10:20:47 pm by RogerHJB »

MarkMLl

  • Hero Member
  • *****
  • Posts: 5866
Re: External: SIGSEGV
« Reply #1 on: December 30, 2022, 10:22:04 pm »
I'm using the same, and don't see anything like that.

Are you doing something like trying to make the change from a background thread without using Synchronize()?

Where did you get your FPC+Lazarus: the official repositories or from whichever distro you're using?

Apart from that I think we really need to see a cut-down project that we can run to try to duplicate the problem.

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

KodeZwerg

  • Hero Member
  • *****
  • Posts: 958
  • Fifty shades of code.
    • Delphi & FreePascal
Re: External: SIGSEGV
« Reply #2 on: December 30, 2022, 11:32:16 pm »
I had that problem once when I accidently f*cked up some rtl units (importing a project overwrote my default unit path)
« Last Edit: Tomorrow at 31:76:97 by KodeZwerg »

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 8621
  • Debugger - SynEdit - and more
    • wiki
Re: External: SIGSEGV
« Reply #3 on: December 30, 2022, 11:46:43 pm »
Start the ide from a terminal/console (use the command startlazarus) => see if it prints anything when the error happens (if lucky it will print a stack trace)


Do a clean rebuild of the IDE.

Tools > Configure Build lazarus
Select the "clean all" radio
Build

RogerHJB

  • New member
  • *
  • Posts: 6
Re: External: SIGSEGV
« Reply #4 on: December 31, 2022, 10:06:48 pm »
Curious thing happened.  I created a test app and duplicated what I had before and I don't get that problem in my test app.  I have restarted my app and so far all seems Ok.  I must have done something wrong the first time.

Thanks for your comments.

RogerHJB

  • New member
  • *
  • Posts: 6
Re: External: SIGSEGV
« Reply #5 on: January 03, 2023, 08:48:52 pm »
Further to the previous post, I got the same erroe again.  I think I have found the problem.  I was using a dynamic array to hold the pertinent information.  I found that if I commented out the code that created the array, the error would go away.  I have now hard coded the size of the array and no more error.  Not sure why this would cause a problem but there it is.

MarkMLl

  • Hero Member
  • *****
  • Posts: 5866
Re: External: SIGSEGV
« Reply #6 on: January 03, 2023, 09:31:56 pm »
Further to the previous post, I got the same erroe again.  I think I have found the problem.  I was using a dynamic array to hold the pertinent information.  I found that if I commented out the code that created the array, the error would go away.  I have now hard coded the size of the array and no more error.  Not sure why this would cause a problem but there it is.

Were you somewhere referring to the address of the dynamic array rather than the address of its first element? The block that describes a dynamic array is distinct from the block which defines its contents.

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

 

TinyPortal © 2005-2018