[Lazarus] Menu editor unstable?

classic Classic list List threaded Threaded
20 messages Options
Reply | Threaded
Open this post in threaded view
|

[Lazarus] Menu editor unstable?

Free Pascal - Lazarus mailing list

Hi,

The menu editor of lazarus trunk seems highly unstable.

I've had 10+ crashes of lazarus in the last 2 hours, all due to the menu editor.

The crash means that I get an access violation and I must actually kill lazarus,
because once I click away the access violation dialog, the lazarus windows
redraw, but respond to no other messages. The only thing that helps is a
KILL signal.

I have not exactly been able to reproduce reliably, but the following just triggered
it:
- Start IDE
- Open project
- Select a popup menu (there are several)
- Double click to edit
- Select menu item 1
- Immediatly select menu item 2.
-> crash.

But also simply selecting something in the menu editor, and going to the object
inspector can crash it.

As a result I find myself saving all files before entering the menu editor.
Not exactly ideal, to say the least.

Anyone else experiencing this ?

Latest Lazarus from SVN. GTK2, linux 64-bit.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable?

Free Pascal - Lazarus mailing list
On Sat, 6 May 2017 21:26:38 +0200 (CEST)
Michael Van Canneyt via Lazarus <[hidden email]> wrote:

>[...]
> I have not exactly been able to reproduce reliably, but the following just triggered
> it:
> - Start IDE
> - Open project
> - Select a popup menu (there are several)
> - Double click to edit
> - Select menu item 1
> - Immediatly select menu item 2.
> -> crash.  
>
> But also simply selecting something in the menu editor, and going to the object
> inspector can crash it.
>
> As a result I find myself saving all files before entering the menu editor.
> Not exactly ideal, to say the least.
>
> Anyone else experiencing this ?
>
> Latest Lazarus from SVN. GTK2, linux 64-bit.

It does not crash here. So it needs something more to trigger the bug.
Maybe the FPC Version?
Stacktrace?

Mattias
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable?

Free Pascal - Lazarus mailing list


On Sun, 7 May 2017, Mattias Gaertner via Lazarus wrote:

> On Sat, 6 May 2017 21:26:38 +0200 (CEST)
> Michael Van Canneyt via Lazarus <[hidden email]> wrote:
>
>> [...]
>> I have not exactly been able to reproduce reliably, but the following just triggered
>> it:
>> - Start IDE
>> - Open project
>> - Select a popup menu (there are several)
>> - Double click to edit
>> - Select menu item 1
>> - Immediatly select menu item 2.
>> -> crash.
>>
>> But also simply selecting something in the menu editor, and going to the object
>> inspector can crash it.
>>
>> As a result I find myself saving all files before entering the menu editor.
>> Not exactly ideal, to say the least.
>>
>> Anyone else experiencing this ?
>>
>> Latest Lazarus from SVN. GTK2, linux 64-bit.
>
> It does not crash here. So it needs something more to trigger the bug.
> Maybe the FPC Version?

3.0.2

> Stacktrace?

I will try to get one.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable?

Free Pascal - Lazarus mailing list
In reply to this post by Free Pascal - Lazarus mailing list
On 05/06/2017 09:26 PM, Michael Van Canneyt via Lazarus wrote:

>
> Hi,
>
> The menu editor of lazarus trunk seems highly unstable.
>
> I've had 10+ crashes of lazarus in the last 2 hours, all due to the menu
> editor.
>
> The crash means that I get an access violation and I must actually kill
> lazarus, because once I click away the access violation dialog, the
> lazarus windows
> redraw, but respond to no other messages. The only thing that helps is a
> KILL signal.
>
> I have not exactly been able to reproduce reliably, but the following
> just triggered
> it:
> - Start IDE
> - Open project
> - Select a popup menu (there are several)
> - Double click to edit
> - Select menu item 1
> - Immediatly select menu item 2.
> -> crash.
>
> But also simply selecting something in the menu editor, and going to the
> object
> inspector can crash it.
>
> As a result I find myself saving all files before entering the menu editor.
> Not exactly ideal, to say the least.
>
> Anyone else experiencing this ?
>
> Latest Lazarus from SVN. GTK2, linux 64-bit.

Not here, but using Lazarus Qt 64-bit + fpc-3.0.2.

zeljko
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
In reply to this post by Free Pascal - Lazarus mailing list


On Sun, 7 May 2017, Michael Van Canneyt wrote:

>
>
> On Sun, 7 May 2017, Mattias Gaertner via Lazarus wrote:
>
>> On Sat, 6 May 2017 21:26:38 +0200 (CEST)
>> Michael Van Canneyt via Lazarus <[hidden email]> wrote:
>>
>>> [...]
>>> I have not exactly been able to reproduce reliably, but the following just
>>> triggered
>>> it:
>>> - Start IDE
>>> - Open project
>>> - Select a popup menu (there are several)
>>> - Double click to edit
>>> - Select menu item 1
>>> - Immediatly select menu item 2.
>>> -> crash.
>>> But also simply selecting something in the menu editor, and going to the
>>> object
>>> inspector can crash it.
>>>
>>> As a result I find myself saving all files before entering the menu
>>> editor.
>>> Not exactly ideal, to say the least.
>>>
>>> Anyone else experiencing this ?
>>>
>>> Latest Lazarus from SVN. GTK2, linux 64-bit.
>>
>> It does not crash here. So it needs something more to trigger the bug.
>> Maybe the FPC Version?
>
> 3.0.2
>
>> Stacktrace?
>
> I will try to get one.

Here it is.

When It happened, I had just selected a menu item, and wanted to change it's
name in the object inspector (I think I was typing the first characters of
the new name, not 100% sure on that).

TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
Hint: (lazarus) TMainIDE.DesignerRenameComponent Old=MenuItem37:TMenuItem New=MIResize Owner=FPReportDesignerForm:TFPReportDesignerForm
WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?
TApplication.HandleException Access violation
   Stack trace:
   $0000000000000000
   $00000000009FD49D line 1617 of ../designer/menueditor.pp
   $0000000000A02673 line 2590 of ../designer/menueditor.pp
   $00000000005B29F8 line 2242 of include/control.inc
   $00000000005B2E61 line 2375 of include/control.inc
   $0000000000436562 line 602 of ../inc/objpas.inc
   $00000000005B28FD line 2202 of include/control.inc
   $00000000005A580C line 5396 of include/wincontrol.inc
   $00000000007722AC line 112 of lclmessageglue.pas
   $000000000066C191 line 3702 of gtk2/gtk2proc.inc
   $000000000067AEC6 line 2137 of gtk2/gtk2callback.inc
   $000000000067A5C8 line 1899 of gtk2/gtk2callback.inc
   $00007F04FDB6EAFC


The WARNING is a bit frightening...
Looking at the stack trace, it looks like FShadowMenu in line 2590 of menueditor is Nil.
Which seems to correspond with the warning ?

After clicking Abort, I get then 2 more AVs:

[TJITComponentList.DestroyJITComponent] ERROR destroying component Error: Access violation
   Stack trace:
   $00000000004E2AD4 line 790 of mainbase.pas
   $00000000004CD54F line 8978 of main.pp
   $000000000090B365 line 6331 of propedits.pp
   $00000000009D95C3 line 3008 of ../designer/designer.pp
   $00000000009D9DEB line 3165 of ../designer/designer.pp
   $000000000048529F line 288 of include/customform.inc
   $000000000053492E line 481 of ../objpas/classes/compon.inc
   $00000000006A4C15 line 131 of lclclasses.pp
   $00000000005B9D59 line 4991 of include/control.inc
   $00000000005A81B8 line 6601 of include/wincontrol.inc
   $00000000005BC54F line 54 of include/customcontrol.inc
   $000000000048394F line 316 of include/scrollingwincontrol.inc
   $0000000000484FF1 line 212 of include/customform.inc
   $0000000000435E81 line 288 of ../inc/objpas.inc
   $00000000009BE1AE line 777 of ../designer/jitforms.pp
   $00000000009BDEDB line 728 of ../designer/jitforms.pp
   $0000000000435E81 line 288 of ../inc/objpas.inc
TCustomFormEditor.JITListException List.CurReadStreamClass=nil nil
TApplication.HandleException: there was another exception during showing the first exception
   Stack trace:
   $0000000000690829 line 768 of laz_avl_tree.pp
   $00000000009E6B69 line 2086 of customformeditor.pp
   $00000000009E0CC1 line 815 of customformeditor.pp
   $00000000009E0C87 line 806 of customformeditor.pp
   $0000000000481346 line 2108 of forms.pp
   $00000000009D9575 line 2995 of ../designer/designer.pp
   $00000000009D9DEB line 3165 of ../designer/designer.pp
   $000000000048529F line 288 of include/customform.inc
   $000000000053492E line 481 of ../objpas/classes/compon.inc
   $000000000090D446 line 7112 of propedits.pp
   $0000000000435E81 line 288 of ../inc/objpas.inc
   $000000000049C913 line 870 of lclproc.pas
   $00000000004AD6C1 line 1662 of main.pp
   $0000000000435E81 line 288 of ../inc/objpas.inc
   $0000000000493A01 line 1093 of include/application.inc
   $0000000000480986 line 1904 of forms.pp
   $000000000043B623 line 972 of ../inc/system.inc
lazarus.pp - unhandled exception

And I need to kill lazarus with a -KILL signal.

Luckily I saved my form just before it happened :)

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable?

Free Pascal - Lazarus mailing list
In reply to this post by Free Pascal - Lazarus mailing list
On 07/05/17 13:08, zeljko via Lazarus wrote:
> Not here, but using Lazarus Qt 64-bit + fpc-3.0.2.
>
Hi,

I can't reproduce it here either, using latest Lazarus GTK2, linux
64-bit, FPC 3.0.2

--
Victor Campillo

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
In reply to this post by Free Pascal - Lazarus mailing list
Can you please create a proper backtrace with gdb using the latest
Lazarus trunk.
It shows also function names and parameter values etc.

I was actually able to reproduce the access violation once but not
more however much I tried.

Juha
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Mon, 8 May 2017, Juha Manninen via Lazarus wrote:

> Can you please create a proper backtrace with gdb using the latest
> Lazarus trunk.
> It shows also function names and parameter values etc.
>
> I was actually able to reproduce the access violation once but not
> more however much I tried.

The stack trace I posted earlier for this issue will have to do.

It's simply *impossible* to debug lazarus using GDB.

I get exceptions from the code tools *ALL THE TIME* because it is timer
triggered. because of this, the working process becomes simply impossible.

And so, every *$รงยง1@#!!! stacktrace looks like this:

#1  0x0000000000c4dcf0 in RAISEEXCEPTIONINSTANCE (this=0x7fffdbad3390, THEEXCEPTION=0x7fffdb508a40, CLEARNICEPOS=true) at customcodetool.pas:2439
#2  0x0000000000c4dd67 in RAISEEXCEPTIONCLASS (this=0x7fffdbad3390, ID=20170421200105, AMESSAGE=0x7fffe0128698 'identifier not found: Name',
     EXCEPTIONCLASS=0x2225010, CLEARNICEPOS=true) at customcodetool.pas:2450
#3  0x0000000000c47dc0 in RAISEEXCEPTION (this=0x7fffdbad3390, ID=20170421200105, AMESSAGE=0x7fffe0128698 'identifier not found: Name', CLEARNICEPOS=true)
     at customcodetool.pas:399
#4  0x0000000000c47e62 in RAISEEXCEPTIONFMT (this=0x7fffdbad3390, ID=20170421200105, AMESSAGE=0x1a6e038 'identifier not found: %s', ARGS=..., highARGS=0,
     CLEARNICEPOS=true) at customcodetool.pas:405
#5  0x0000000000861726 in RAISENOTFOUND (parentfp=0x7fffffffcf50) at finddeclarationtool.pas:4071
#6  0x000000000086159e in CHECKRESULT (parentfp=0x7fffffffcfe0, NEWRESULT=false, CALLONIDENTIFIERFOUND=false) at finddeclarationtool.pas:4177
#7  0x000000000085fd3d in FINDIDENTIFIERINCONTEXT (this=0x7fffdbad3390, PARAMS=0x7fffe927b4e0, IDENTFOUNDRESULT=(unknown: 3685561232))
     at finddeclarationtool.pas:4998
#8  0x0000000000867d05 in FINDIDENTIFIERINCONTEXT (this=0x7fffdbad3390, PARAMS=0x7fffe927b4e0) at finddeclarationtool.pas:7163
#9  0x00000000008595f7 in FINDDECLARATION (this=0x7fffdbad3390, CURSORPOS=..., SEARCHSMARTFLAGS=4, NEWEXPRTYPE=..., NEWPOS=..., NEWTOPLINE=-610849184)
     at finddeclarationtool.pas:2409
#10 0x0000000000859f54 in FINDDECLARATION (this=0x7fffdbad3390, CURSORPOS=..., SEARCHSMARTFLAGS=4, NEWTOOL=0x7fffdbad3390, NEWNODE=0x7fffdb972e60,
     NEWPOS=..., NEWTOPLINE=-610849184) at finddeclarationtool.pas:2468
#11 0x00000000009b6c13 in GETHTMLHINTFOREXPR (this=0x7fffe9787540, CTEXPRTYPE=..., XYPOS=..., OPTIONS=0, BASEURL=0x1a98e20 'lazdoc://', HTMLHINT=0x0,
     CACHEWASUSED=false) at codehelp.pas:2601
#12 0x00000000009b6267 in GETHTMLHINT (this=0x7fffe9787540, CODE=0x7fffe82367e0, X=14, Y=1872, OPTIONS=0, BASEURL=0x1a98e20 'lazdoc://', HTMLHINT=0x0,
     PROPDETAILS=0x0, CACHEWASUSED=false) at codehelp.pas:2469
#13 0x00000000004d96a6 in OICHANGEDTIMERTIMER (this=0x7ffff7f99550, SENDER=0x7fffe80448c0) at main.pp:12191
#14 0x0000000000752b94 in DOONTIMER (this=0x7fffe80448c0) at customtimer.pas:175
#15 0x0000000000752ae5 in TIMER (this=0x7fffe80448c0) at customtimer.pas:150

This error is obviously bogus, since the compiler processes the program fine.

So the original stack trace which I posted should suffice to diagnose the
problem:

ObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
Hint: (lazarus) TMainIDE.DesignerRenameComponent Old=MenuItem37:TMenuItem New=MIResize Owner=FPReportDesignerForm:TFPReportDesignerForm
WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?
TApplication.HandleException Access violation
    Stack trace:
    $0000000000000000
    $00000000009FD49D line 1617 of ../designer/menueditor.pp
    $0000000000A02673 line 2590 of ../designer/menueditor.pp
    $00000000005B29F8 line 2242 of include/control.inc
    $00000000005B2E61 line 2375 of include/control.inc
    $0000000000436562 line 602 of ../inc/objpas.inc
    $00000000005B28FD line 2202 of include/control.inc
    $00000000005A580C line 5396 of include/wincontrol.inc
    $00000000007722AC line 112 of lclmessageglue.pas
    $000000000066C191 line 3702 of gtk2/gtk2proc.inc
    $000000000067AEC6 line 2137 of gtk2/gtk2callback.inc
    $000000000067A5C8 line 1899 of gtk2/gtk2callback.inc
    $00007F04FDB6EAFC


The 2 following lines should tell you everything you need, IMHO:
    $00000000009FD49D line 1617 of ../designer/menueditor.pp
    $0000000000A02673 line 2590 of ../designer/menueditor.pp

The GDB stack trace will give you little more useful information.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
y

On Mon, 8 May 2017, Michael Van Canneyt via Lazarus wrote:

>
>
> On Mon, 8 May 2017, Juha Manninen via Lazarus wrote:
>
>> Can you please create a proper backtrace with gdb using the latest
>> Lazarus trunk.
>> It shows also function names and parameter values etc.
>>
>> I was actually able to reproduce the access violation once but not
>> more however much I tried.
>
> The stack trace I posted earlier for this issue will have to do.
>
> It's simply *impossible* to debug lazarus using GDB.

As always, you get an idea after sending a mail saying you don't find it... :/

I managed to produce a stacktrace. Hopefully this, combined with the stacktrace
at the end is sufficient to solve the issue.

Michael.

(gdb) cont
Continuing.
WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?
Thread 1 "lazarus" received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x00000000009fd6f2 in SETSELECTEDSHADOW (this=0x7fffe02077b0, PREVSELECTEDITEM=0x7fffe37107c0, CURSELECTEDITEM=0x7fffe03c1e80, VIADESIGNER=false)
     at ../designer/menueditor.pp:1663
#2  0x00000000009fd49d in SETSELECTEDMENUITEM (this=0x7fffe02077b0, AMI=0x7fffe03c1e80, VIADESIGNER=false, PREVWASDELETED=false)
     at ../designer/menueditor.pp:1617
#3  0x0000000000a02673 in MOUSEDOWN (this=0x7fffe9371e10, BUTTON=MBLEFT, SHIFT=8, X=73, Y=8) at ../designer/menueditor.pp:2590
#4  0x00000000005b29f8 in DOMOUSEDOWN (this=0x7fffe9371e10, MESSAGE=..., BUTTON=MBLEFT, SHIFT=0) at include/control.inc:2242
#5  0x00000000005b2e61 in WMLBUTTONDOWN (this=0x7fffe9371e10, MESSAGE=...) at include/control.inc:2375
#6  0x0000000000436562 in DISPATCH (this=0x7fffe9371e10, MESSAGE=0) at ../inc/objpas.inc:602
#7  0x00000000005b28fd in WNDPROC (this=0x7fffe9371e10, THEMESSAGE=...) at include/control.inc:2202
#8  0x00000000005a580c in WNDPROC (this=0x7fffe9371e10, MESSAGE=...) at include/wincontrol.inc:5396
#9  0x00000000007722ac in DELIVERMESSAGE (TARGET=0x7fffe9371e10, AMESSAGE=0) at lclmessageglue.pas:112
#10 0x000000000066c191 in DELIVERMESSAGE (TARGET=0x7fffe9371e10, AMESSAGE=0) at gtk2/gtk2proc.inc:3702
#11 0x000000000067aec6 in DELIVERMOUSEDOWNMESSAGE (WIDGET=0x3aced90, EVENT=0x3624ea0, AWINCONTROL=0x7fffe9371e10) at gtk2/gtk2callback.inc:2137
#12 0x000000000067a5c8 in GTKMOUSEBTNPRESS (WIDGET=0x32d2b80, EVENT=0x3624ea0, DATA=0x7fffe9371e10) at gtk2/gtk2callback.inc:1899
#13 0x00007ffff6c8cafc in ?? () from /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#14 0x00007ffff6916fa5 in g_closure_invoke () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#15 0x00007ffff6928fc1 in ?? () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#16 0x00007ffff69317f9 in g_signal_emit_valist () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#17 0x00007ffff693208f in g_signal_emit () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#18 0x00007ffff6da48cc in ?? () from /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#19 0x00007ffff6c8b294 in gtk_propagate_event () from /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#20 0x00007ffff6c8b64b in gtk_main_do_event () from /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#21 0x00007ffff775bc4c in ?? () from /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0
#22 0x00007ffff6640197 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#23 0x00007ffff66403f0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#24 0x00007ffff664049c in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#25 0x00000000004fc6ec in APPPROCESSMESSAGES (this=0x7ffff7f75230) at gtk2/gtk2widgetset.inc:2338
#26 0x000000000049435d in HANDLEMESSAGE (this=0x7ffff7f74bf0) at include/application.inc:1276
#27 0x00000000004948ac in RUNLOOP (this=0x7ffff7f74bf0) at include/application.inc:1413
#28 0x00000000006585a6 in APPRUN (this=0x7ffff7f75230, ALOOP=...) at include/interfacebase.inc:54
#29 0x0000000000494850 in RUN (this=0x7ffff7f74bf0) at include/application.inc:1401
#30 0x0000000000420127 in main () at lazarus.pp:145
(gdb) cont
Continuing.
TApplication.HandleException Access violation
   Stack trace:
   $0000000000000000
   $00000000009FD49D line 1617 of ../designer/menueditor.pp
   $0000000000A02673 line 2590 of ../designer/menueditor.pp
   $00000000005B29F8 line 2242 of include/control.inc
   $00000000005B2E61 line 2375 of include/control.inc
   $0000000000436562 line 602 of ../inc/objpas.inc
   $00000000005B28FD line 2202 of include/control.inc
   $00000000005A580C line 5396 of include/wincontrol.inc
   $00000000007722AC line 112 of lclmessageglue.pas
   $000000000066C191 line 3702 of gtk2/gtk2proc.inc
   $000000000067AEC6 line 2137 of gtk2/gtk2callback.inc
   $000000000067A5C8 line 1899 of gtk2/gtk2callback.inc
   $00007FFFF6C8CAFC
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
Am 08.05.2017 um 15:09 schrieb Michael Van Canneyt via Lazarus:

> I managed to produce a stacktrace. Hopefully this, combined with the
> stacktrace
> at the end is sufficient to solve the issue.
>
> Michael.
>
> (gdb) cont
> Continuing.
> WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the
> component is processing an event?
> Thread 1 "lazarus" received signal SIGSEGV, Segmentation fault.
> 0x0000000000000000 in ?? ()
> (gdb) bt
> #0  0x0000000000000000 in ?? ()
> #1  0x00000000009fd6f2 in SETSELECTEDSHADOW (this=0x7fffe02077b0,
> PREVSELECTEDITEM=0x7fffe37107c0, CURSELECTEDITEM=0x7fffe03c1e80,
> VIADESIGNER=false)
>     at ../designer/menueditor.pp:1663
> #2  0x00000000009fd49d in SETSELECTEDMENUITEM (this=0x7fffe02077b0,
> AMI=0x7fffe03c1e80, VIADESIGNER=false, PREVWASDELETED=false)
>     at ../designer/menueditor.pp:1617
> #3  0x0000000000a02673 in MOUSEDOWN (this=0x7fffe9371e10,
> BUTTON=MBLEFT, SHIFT=8, X=73, Y=8) at ../designer/menueditor.pp:2590
> #4  0x00000000005b29f8 in DOMOUSEDOWN (this=0x7fffe9371e10,
> MESSAGE=..., BUTTON=MBLEFT, SHIFT=0) at include/control.inc:2242
> #5  0x00000000005b2e61 in WMLBUTTONDOWN (this=0x7fffe9371e10,
> MESSAGE=...) at include/control.inc:2375
> #6  0x0000000000436562 in DISPATCH (this=0x7fffe9371e10, MESSAGE=0) at
> ../inc/objpas.inc:602
> #7  0x00000000005b28fd in WNDPROC (this=0x7fffe9371e10,
> THEMESSAGE=...) at include/control.inc:2202
> #8  0x00000000005a580c in WNDPROC (this=0x7fffe9371e10, MESSAGE=...)
> at include/wincontrol.inc:5396
> #9  0x00000000007722ac in DELIVERMESSAGE (TARGET=0x7fffe9371e10,
> AMESSAGE=0) at lclmessageglue.pas:112
> #10 0x000000000066c191 in DELIVERMESSAGE (TARGET=0x7fffe9371e10,
> AMESSAGE=0) at gtk2/gtk2proc.inc:3702
> #11 0x000000000067aec6 in DELIVERMOUSEDOWNMESSAGE (WIDGET=0x3aced90,
> EVENT=0x3624ea0, AWINCONTROL=0x7fffe9371e10) at
> gtk2/gtk2callback.inc:2137
> #12 0x000000000067a5c8 in GTKMOUSEBTNPRESS (WIDGET=0x32d2b80,
> EVENT=0x3624ea0, DATA=0x7fffe9371e10) at gtk2/gtk2callback.inc:1899
> #13 0x00007ffff6c8cafc in ?? () from
> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
> #14 0x00007ffff6916fa5 in g_closure_invoke () from
> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
> #15 0x00007ffff6928fc1 in ?? () from
> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
> #16 0x00007ffff69317f9 in g_signal_emit_valist () from
> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
> #17 0x00007ffff693208f in g_signal_emit () from
> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
> #18 0x00007ffff6da48cc in ?? () from
> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
> #19 0x00007ffff6c8b294 in gtk_propagate_event () from
> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
> #20 0x00007ffff6c8b64b in gtk_main_do_event () from
> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
> #21 0x00007ffff775bc4c in ?? () from
> /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0
> #22 0x00007ffff6640197 in g_main_context_dispatch () from
> /lib/x86_64-linux-gnu/libglib-2.0.so.0
> #23 0x00007ffff66403f0 in ?? () from
> /lib/x86_64-linux-gnu/libglib-2.0.so.0
> #24 0x00007ffff664049c in g_main_context_iteration () from
> /lib/x86_64-linux-gnu/libglib-2.0.so.0
> #25 0x00000000004fc6ec in APPPROCESSMESSAGES (this=0x7ffff7f75230) at
> gtk2/gtk2widgetset.inc:2338
> #26 0x000000000049435d in HANDLEMESSAGE (this=0x7ffff7f74bf0) at
> include/application.inc:1276
> #27 0x00000000004948ac in RUNLOOP (this=0x7ffff7f74bf0) at
> include/application.inc:1413
> #28 0x00000000006585a6 in APPRUN (this=0x7ffff7f75230, ALOOP=...) at
> include/interfacebase.inc:54
> #29 0x0000000000494850 in RUN (this=0x7ffff7f74bf0) at
> include/application.inc:1401
> #30 0x0000000000420127 in main () at lazarus.pp:145
> (gdb) cont
> Continuing.
> TApplication.HandleException Access violation
>   Stack trace:
>   $0000000000000000
>   $00000000009FD49D line 1617 of ../designer/menueditor.pp
>   $0000000000A02673 line 2590 of ../designer/menueditor.pp
>   $00000000005B29F8 line 2242 of include/control.inc
>   $00000000005B2E61 line 2375 of include/control.inc
>   $0000000000436562 line 602 of ../inc/objpas.inc
>   $00000000005B28FD line 2202 of include/control.inc
>   $00000000005A580C line 5396 of include/wincontrol.inc
>   $00000000007722AC line 112 of lclmessageglue.pas
>   $000000000066C191 line 3702 of gtk2/gtk2proc.inc
>   $000000000067AEC6 line 2137 of gtk2/gtk2callback.inc
>   $000000000067A5C8 line 1899 of gtk2/gtk2callback.inc
>   $00007FFFF6C8CAFC

As I've made some bug fixes for the Menueditor last time, I tried to
reproduce this error. Till now I wasn't able to reproduce it on Lazarus
Trunk revision 54826 with FPC 3.0.2 on Windows 7, 10, OpenSuse 42.2 KDE
GTK2 or Linux Mint 17.3 KDE GTK2. I currently install on a VM a 64bit
Linux Mint 18.1 Cinnamon (your OS?!), to test the issue there.

I'll report.

Michl
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Mon, 8 May 2017, Michael W. Vogel via Lazarus wrote:

> Am 08.05.2017 um 15:09 schrieb Michael Van Canneyt via Lazarus:
>> I managed to produce a stacktrace. Hopefully this, combined with the
>> stacktrace
>> at the end is sufficient to solve the issue.
>>
>> Michael.
>>
>> (gdb) cont
>> Continuing.
>> WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the
>> component is processing an event?
>> Thread 1 "lazarus" received signal SIGSEGV, Segmentation fault.
>> 0x0000000000000000 in ?? ()
>> (gdb) bt
>> #0  0x0000000000000000 in ?? ()
>> #1  0x00000000009fd6f2 in SETSELECTEDSHADOW (this=0x7fffe02077b0,
>> PREVSELECTEDITEM=0x7fffe37107c0, CURSELECTEDITEM=0x7fffe03c1e80,
>> VIADESIGNER=false)
>>     at ../designer/menueditor.pp:1663
>> #2  0x00000000009fd49d in SETSELECTEDMENUITEM (this=0x7fffe02077b0,
>> AMI=0x7fffe03c1e80, VIADESIGNER=false, PREVWASDELETED=false)
>>     at ../designer/menueditor.pp:1617
>> #3  0x0000000000a02673 in MOUSEDOWN (this=0x7fffe9371e10,
>> BUTTON=MBLEFT, SHIFT=8, X=73, Y=8) at ../designer/menueditor.pp:2590
>> #4  0x00000000005b29f8 in DOMOUSEDOWN (this=0x7fffe9371e10,
>> MESSAGE=..., BUTTON=MBLEFT, SHIFT=0) at include/control.inc:2242
>> #5  0x00000000005b2e61 in WMLBUTTONDOWN (this=0x7fffe9371e10,
>> MESSAGE=...) at include/control.inc:2375
>> #6  0x0000000000436562 in DISPATCH (this=0x7fffe9371e10, MESSAGE=0) at
>> ../inc/objpas.inc:602
>> #7  0x00000000005b28fd in WNDPROC (this=0x7fffe9371e10,
>> THEMESSAGE=...) at include/control.inc:2202
>> #8  0x00000000005a580c in WNDPROC (this=0x7fffe9371e10, MESSAGE=...)
>> at include/wincontrol.inc:5396
>> #9  0x00000000007722ac in DELIVERMESSAGE (TARGET=0x7fffe9371e10,
>> AMESSAGE=0) at lclmessageglue.pas:112
>> #10 0x000000000066c191 in DELIVERMESSAGE (TARGET=0x7fffe9371e10,
>> AMESSAGE=0) at gtk2/gtk2proc.inc:3702
>> #11 0x000000000067aec6 in DELIVERMOUSEDOWNMESSAGE (WIDGET=0x3aced90,
>> EVENT=0x3624ea0, AWINCONTROL=0x7fffe9371e10) at
>> gtk2/gtk2callback.inc:2137
>> #12 0x000000000067a5c8 in GTKMOUSEBTNPRESS (WIDGET=0x32d2b80,
>> EVENT=0x3624ea0, DATA=0x7fffe9371e10) at gtk2/gtk2callback.inc:1899
>> #13 0x00007ffff6c8cafc in ?? () from
>> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
>> #14 0x00007ffff6916fa5 in g_closure_invoke () from
>> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
>> #15 0x00007ffff6928fc1 in ?? () from
>> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
>> #16 0x00007ffff69317f9 in g_signal_emit_valist () from
>> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
>> #17 0x00007ffff693208f in g_signal_emit () from
>> /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
>> #18 0x00007ffff6da48cc in ?? () from
>> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
>> #19 0x00007ffff6c8b294 in gtk_propagate_event () from
>> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
>> #20 0x00007ffff6c8b64b in gtk_main_do_event () from
>> /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
>> #21 0x00007ffff775bc4c in ?? () from
>> /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0
>> #22 0x00007ffff6640197 in g_main_context_dispatch () from
>> /lib/x86_64-linux-gnu/libglib-2.0.so.0
>> #23 0x00007ffff66403f0 in ?? () from
>> /lib/x86_64-linux-gnu/libglib-2.0.so.0
>> #24 0x00007ffff664049c in g_main_context_iteration () from
>> /lib/x86_64-linux-gnu/libglib-2.0.so.0
>> #25 0x00000000004fc6ec in APPPROCESSMESSAGES (this=0x7ffff7f75230) at
>> gtk2/gtk2widgetset.inc:2338
>> #26 0x000000000049435d in HANDLEMESSAGE (this=0x7ffff7f74bf0) at
>> include/application.inc:1276
>> #27 0x00000000004948ac in RUNLOOP (this=0x7ffff7f74bf0) at
>> include/application.inc:1413
>> #28 0x00000000006585a6 in APPRUN (this=0x7ffff7f75230, ALOOP=...) at
>> include/interfacebase.inc:54
>> #29 0x0000000000494850 in RUN (this=0x7ffff7f74bf0) at
>> include/application.inc:1401
>> #30 0x0000000000420127 in main () at lazarus.pp:145
>> (gdb) cont
>> Continuing.
>> TApplication.HandleException Access violation
>>   Stack trace:
>>   $0000000000000000
>>   $00000000009FD49D line 1617 of ../designer/menueditor.pp
>>   $0000000000A02673 line 2590 of ../designer/menueditor.pp
>>   $00000000005B29F8 line 2242 of include/control.inc
>>   $00000000005B2E61 line 2375 of include/control.inc
>>   $0000000000436562 line 602 of ../inc/objpas.inc
>>   $00000000005B28FD line 2202 of include/control.inc
>>   $00000000005A580C line 5396 of include/wincontrol.inc
>>   $00000000007722AC line 112 of lclmessageglue.pas
>>   $000000000066C191 line 3702 of gtk2/gtk2proc.inc
>>   $000000000067AEC6 line 2137 of gtk2/gtk2callback.inc
>>   $000000000067A5C8 line 1899 of gtk2/gtk2callback.inc
>>   $00007FFFF6C8CAFC
>
> As I've made some bug fixes for the Menueditor last time, I tried to
> reproduce this error. Till now I wasn't able to reproduce it on Lazarus
> Trunk revision 54826 with FPC 3.0.2 on Windows 7, 10, OpenSuse 42.2 KDE
> GTK2 or Linux Mint 17.3 KDE GTK2. I currently install on a VM a 64bit
> Linux Mint 18.1 Cinnamon (your OS?!), to test the issue there.

OK.
It seems clear to me that something is being freed which should not yet be
freed:

>> WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the
>> component is processing an event?

This indicates to me that an unforeseen order of events is happening ?
As far as I know, there is a global call to free components once the
message processing is finished ?

Well, I hope you can reproduce it...

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
Am 08.05.2017 um 15:54 schrieb Michael Van Canneyt via Lazarus:

>
> OK. It seems clear to me that something is being freed which should
> not yet be
> freed:
>
>>> WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the
>>> component is processing an event?
>
> This indicates to me that an unforeseen order of events is happening ?
> As far as I know, there is a global call to free components once the
> message processing is finished ?
>
> Well, I hope you can reproduce it...

Sorry, I don't get it. After over two hours of testing with 64bit Linux
Mint 18.1 Cinnamon and Lazarus 1.9.0 r54833M FPC 3.0.2
x86_64-linux-gtk2, with new or saved projects, without or with
AnchorDockingDsgn / Sparta_DockedFormEditor, I'm not able to create a
crash.

I tried this steps and around:
- Open project
- Select a popup menu (there are several)
- Double click to edit
- Select menu item 1
- Immediatly select menu item 2


If you want, you can add a minimal example and explain every single step
again, what you do, to create a crash. Then, I'll test again, but for
now, I don't know what to do more.

What Lazarus revision are you using?
Do you have installed AnchorDockingDsgn, Sparta_DockedFormEditor or
something similar?


Kind regards

Michl



--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Mon, 8 May 2017, Michael W. Vogel via Lazarus wrote:

> Am 08.05.2017 um 15:54 schrieb Michael Van Canneyt via Lazarus:
>>
>> OK. It seems clear to me that something is being freed which should
>> not yet be
>> freed:
>>
>>>> WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the
>>>> component is processing an event?
>>
>> This indicates to me that an unforeseen order of events is happening ?
>> As far as I know, there is a global call to free components once the
>> message processing is finished ?
>>
>> Well, I hope you can reproduce it...
>
> Sorry, I don't get it. After over two hours of testing with 64bit Linux
> Mint 18.1 Cinnamon and Lazarus 1.9.0 r54833M FPC 3.0.2
> x86_64-linux-gtk2, with new or saved projects, without or with
> AnchorDockingDsgn / Sparta_DockedFormEditor, I'm not able to create a
> crash.
>
> I tried this steps and around:
> - Open project
> - Select a popup menu (there are several)
> - Double click to edit
> - Select menu item 1
> - Immediatly select menu item 2

Here, the crash happens when going to the object inspector.

>
>
> If you want, you can add a minimal example and explain every single step
> again, what you do, to create a crash. Then, I'll test again, but for
> now, I don't know what to do more.

I will try. I do use actions.

> What Lazarus revision are you using?
> Do you have installed AnchorDockingDsgn, Sparta_DockedFormEditor or
> something similar?

No, no docking whatsoever.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


>> - Open project
>> - Select a popup menu (there are several)
>> - Double click to edit
>> - Select menu item 1
>> - Immediatly select menu item 2
>
> Here, the crash happens when going to the object inspector.
>
>>
>>
>> If you want, you can add a minimal example and explain every single step
>> again, what you do, to create a crash. Then, I'll test again, but for
>> now, I don't know what to do more.
>
> I will try. I do use actions.
>
>> What Lazarus revision are you using?
>> Do you have installed AnchorDockingDsgn, Sparta_DockedFormEditor or
>> something similar?

Hi,

I manage to reliably reproduce it !

1 Open attached project.
2 Double click MainMenu1 to edit
3 Under MenuItem5, delete MenuItem14,13,12,11
   (I use the - button in the menu editor)
4 The last menu item under MenuItem5 is then 'Action3'
5 Add new menu item (I click 'add menu item' below the Action3 item)
6 Click on Action 3
7 Click on the newly added (in step 5) MenuItem11
--->> BOOM

Never fails.

The delete step 3 is important. Without that, I don't get a crash.
I then tested deleting a single item instead of 4 items as described above,
then I also get a crash. So as soon as a delete is performed - boom...

Michael.


--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list

Forgot attachment :(

Michael.

On Tue, 9 May 2017, Michael Van Canneyt via Lazarus wrote:

>
>
>>> - Open project
>>> - Select a popup menu (there are several)
>>> - Double click to edit
>>> - Select menu item 1
>>> - Immediatly select menu item 2
>>
>> Here, the crash happens when going to the object inspector.
>>
>>>
>>>
>>> If you want, you can add a minimal example and explain every single step
>>> again, what you do, to create a crash. Then, I'll test again, but for
>>> now, I don't know what to do more.
>>
>> I will try. I do use actions.
>>
>>> What Lazarus revision are you using?
>>> Do you have installed AnchorDockingDsgn, Sparta_DockedFormEditor or
>>> something similar?
>
> Hi,
>
> I manage to reliably reproduce it !
>
> 1 Open attached project.
> 2 Double click MainMenu1 to edit
> 3 Under MenuItem5, delete MenuItem14,13,12,11
>   (I use the - button in the menu editor)
> 4 The last menu item under MenuItem5 is then 'Action3'
> 5 Add new menu item (I click 'add menu item' below the Action3 item)
> 6 Click on Action 3
> 7 Click on the newly added (in step 5) MenuItem11
> --->> BOOM
>
> Never fails.
>
> The delete step 3 is important. Without that, I don't get a crash.
> I then tested deleting a single item instead of 4 items as described above,
> then I also get a crash. So as soon as a delete is performed - boom...
>
> Michael.
>
>
> --
> _______________________________________________
> Lazarus mailing list
> [hidden email]
> http://lists.lazarus-ide.org/listinfo/lazarus
>
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus

bug.zip (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
In reply to this post by Free Pascal - Lazarus mailing list
Am 09.05.2017 um 15:15 schrieb Michael Van Canneyt via Lazarus:

> Hi,
>
> I manage to reliably reproduce it !
>
> 1 Open attached project.
> 2 Double click MainMenu1 to edit
> 3 Under MenuItem5, delete MenuItem14,13,12,11
>   (I use the - button in the menu editor)
> 4 The last menu item under MenuItem5 is then 'Action3'
> 5 Add new menu item (I click 'add menu item' below the Action3 item)
> 6 Click on Action 3
> 7 Click on the newly added (in step 5) MenuItem11 --->> BOOM
>
> Never fails.
>
> The delete step 3 is important. Without that, I don't get a crash.
> I then tested deleting a single item instead of 4 items as described
> above,
> then I also get a crash. So as soon as a delete is performed - boom...

Thank you for your exact explanation and test project! But sorry again,
again I don't get it.

I have tested here:
64bit Linux Mint 18.1 Cinnamon, GTK2 version 2.24.30, Lazarus 1.9.0
r54844 FPC 3.0.2 x86_64-linux-gtk2
64bit Linux Mint 17.3 KDE, GTK2 version 2.24.23, Lazarus 1.9.0 r54826
FPC 3.0.2 x86_64-linux-gtk2
64bit OpenSuse Leap 42.2 KDE GTK2 version 2.24.31, Lazarus 1.9.0 r54809
FPC 3.0.2 x86_64-linux-gtk2
64bit Windows 7, Lazarus 1.9.0 r54844 FPC 3.0.2 x86_64-win64-win32/win64

Maybe it is a problem with your GTK2 version?
Maybe it is a problem with your OS?
Maybe it was fixed in meantime?
Maybe you have a broken installation of Lazarus?
Maybe it is a timing problem (as my development pc was out of order, I
bought a relativ fast Core I5, so I'm not fast enough to click)?

Maybe it is better to open a bugreport about that issue? Then we can
better gather informations about it.

Is there anybody else how can create a crash with the test project and
the steps above?

Michl
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Tue, 9 May 2017, Michael W. Vogel via Lazarus wrote:

> Am 09.05.2017 um 15:15 schrieb Michael Van Canneyt via Lazarus:
>> Hi,
>>
>> I manage to reliably reproduce it !
>>
>> 1 Open attached project.
>> 2 Double click MainMenu1 to edit
>> 3 Under MenuItem5, delete MenuItem14,13,12,11
>>   (I use the - button in the menu editor)
>> 4 The last menu item under MenuItem5 is then 'Action3'
>> 5 Add new menu item (I click 'add menu item' below the Action3 item)
>> 6 Click on Action 3
>> 7 Click on the newly added (in step 5) MenuItem11 --->> BOOM
>>
>> Never fails.
>>
>> The delete step 3 is important. Without that, I don't get a crash.
>> I then tested deleting a single item instead of 4 items as described
>> above,
>> then I also get a crash. So as soon as a delete is performed - boom...
>
> Thank you for your exact explanation and test project! But sorry again,
> again I don't get it.
>
> I have tested here:
> 64bit Linux Mint 18.1 Cinnamon, GTK2 version 2.24.30, Lazarus 1.9.0
> r54844 FPC 3.0.2 x86_64-linux-gtk2

This is the exact version I am using. (lazarus SVN version may differ, but
it is the day before yesterday's SVN version)

>
> Maybe it is a problem with your GTK2 version?
> Maybe it is a problem with your OS?

They are the same as yours.


> Maybe it was fixed in meantime?
> Maybe you have a broken installation of Lazarus?

Define broken ? It's a clean SVN update.

> Maybe it is a timing problem (as my development pc was out of order, I
> bought a relativ fast Core I5, so I'm not fast enough to click)?

Clicking speed has nothing to do with it.
I can wait a second, 2 seconds. Doesn't matter.

The only thing that matters is the delete.

I wish to point out that there is a LCL warning about freeing an item with
LCLCount>1, which clearly points at a logic error: something is probably
being freed twice.

> Maybe it is better to open a bugreport about that issue? Then we can
> better gather informations about it.

I will post the steps and project in the bugtracker.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list
On Wed, 10 May 2017 00:06:35 +0200 (CEST)
Michael Van Canneyt via Lazarus <[hidden email]> wrote:

>[...]
> > I have tested here:
> > 64bit Linux Mint 18.1 Cinnamon, GTK2 version 2.24.30, Lazarus 1.9.0
> > r54844 FPC 3.0.2 x86_64-linux-gtk2  
>
> This is the exact version I am using. (lazarus SVN version may differ, but
> it is the day before yesterday's SVN version)
>
> >
> > Maybe it is a problem with your GTK2 version?
> > Maybe it is a problem with your OS?  
>
> They are the same as yours.

Maybe the bug is not in the menu editor, but in an installed package
and the menu editor is only the symptom?
Try uninstalling all unneeded packages. Does that change anything?

Mattias
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Wed, 10 May 2017, Mattias Gaertner via Lazarus wrote:

> On Wed, 10 May 2017 00:06:35 +0200 (CEST)
> Michael Van Canneyt via Lazarus <[hidden email]> wrote:
>
>> [...]
>> > I have tested here:
>> > 64bit Linux Mint 18.1 Cinnamon, GTK2 version 2.24.30, Lazarus 1.9.0
>> > r54844 FPC 3.0.2 x86_64-linux-gtk2
>>
>> This is the exact version I am using. (lazarus SVN version may differ, but
>> it is the day before yesterday's SVN version)
>>
>> >
>> > Maybe it is a problem with your GTK2 version?
>> > Maybe it is a problem with your OS?
>>
>> They are the same as yours.
>
> Maybe the bug is not in the menu editor, but in an installed package
> and the menu editor is only the symptom?
> Try uninstalling all unneeded packages. Does that change anything?

I created a minimal IDE without any additional packages installed ('make all').
Latest SVN.  Revision 54848. (I did an svn update). FPC 3.0.2.
No defines are set when building the IDE

And I still get the error, I did as I outlined before. I waited 5 (five!)
seconds before clicking on the newly added item. That should eliminate
any possible timing issues.

I remind you that the LCL *warns* that something is wrong:

WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?

This line alone should IMHO be enough to tell the IDE people that something
is actually going wrong.

Below is the output on the console when I do the steps as I outlined them
above.

I have reported it as a bug.
https://bugs.freepascal.org/view.php?id=31791

Michael.

TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?
Hint: (lazarus) TMainIDE.OnPropHookDeletePersistent A MenuItem14:TMenuItem
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
Hint: (lazarus) TMainIDE.OnPropHookDeletePersistent A MenuItem13:TMenuItem
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
Hint: (lazarus) TMainIDE.OnPropHookDeletePersistent A MenuItem12:TMenuItem
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
Hint: (lazarus) TMainIDE.OnPropHookDeletePersistent A MenuItem11:TMenuItem
TObjectInspectorDlg.FillPersistentComboBox: Updating ComboBox with components
WARNING: TShadowItem.Destroy with LCLRefCount>0. Hint: Maybe the component is processing an event?
TApplication.HandleException Access violation
   Stack trace:
   $0000000000000000
   $0000000000A08B7D line 1606 of ../designer/menueditor.pp
   $0000000000A0DD03 line 2578 of ../designer/menueditor.pp
   $00000000005B467A line 2242 of include/control.inc
   $00000000005B4B17 line 2375 of include/control.inc
   $0000000000434EF2 line 602 of ../inc/objpas.inc
   $00000000005B457F line 2202 of include/control.inc
   $00000000005A6FAD line 5396 of include/wincontrol.inc
   $000000000077B7A2 line 112 of lclmessageglue.pas
   $0000000000673075 line 3702 of gtk2proc.inc
   $00000000006826EA line 2137 of gtk2callback.inc
   $0000000000681D68 line 1899 of gtk2callback.inc
   $00007FCBE2536AFC

--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Menu editor unstable? - stack trace

Free Pascal - Lazarus mailing list


On Wed, 10 May 2017, Michael Van Canneyt via Lazarus wrote:

>
> I have reported it as a bug.
> https://bugs.freepascal.org/view.php?id=31791

I attached 2 backtraces to the bug report.
One when the warning happens (I put a breakpoint there)

One when the AV happens.

Hopefully this helps.

Michael.
--
_______________________________________________
Lazarus mailing list
[hidden email]
http://lists.lazarus-ide.org/listinfo/lazarus