octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #63180] Octave crashes opening a GUI with an i


From: Markus Mützel
Subject: [Octave-bug-tracker] [bug #63180] Octave crashes opening a GUI with an indexed object and menu with callback
Date: Fri, 7 Oct 2022 12:20:22 -0400 (EDT)

Update of bug #63180 (project octave):

              Item Group: Unexpected Error or Warning => Segfault, Bus Error,
etc.
                  Status:                    None => Confirmed              

    _______________________________________________________

Follow-up Comment #1:

Confirmed here with Octave 7.2.0 on Windows.

Executing `myGui` closes Octave unexpectedly.
`gdb` doesn't catch anything. All threads and the entire process just exit
with code 3. No backtrace.

I then attached `gdb`, set a breakpoint in `abort`, and executed the function
again.
With that, I got this backtrace:

Thread 25 hit Breakpoint 1, 0x00007ff9f3c82547 in msvcrt!abort () from
C:\WINDOWS\System32\msvcrt.dll
(gdb) bt
#0  0x00007ff9f3c82547 in msvcrt!abort () from C:\WINDOWS\System32\msvcrt.dll
#1  0x000000006fc6146a in
libstdc++-6!_ZN9__gnu_cxx27__verbose_terminate_handlerEv ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#2  0x000000006fc57a66 in libstdc++-6!_ZGTtNKSt9exceptionD1Ev ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#3  0x000000006fd522e3 in libstdc++-6!.cxa_begin_catch ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#4  0x000000006fc57ddc in
libstdc++-6!_ZN10__cxxabiv129__pointer_to_member_type_infoD2Ev ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#5  0x000000006144d075 in libgcc_s_seh-1!_GCC_specific_handler ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libgcc_s_seh-1.dll
#6  0x000000006fd532c5 in libstdc++-6!.gxx_personality_seh0 ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#7  0x00007ff9f58b3e1f in ntdll!.chkstk () from C:\WINDOWS\SYSTEM32\ntdll.dll
#8  0x00007ff9f582eae6 in ntdll!RtlFindCharInUnicodeString () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#9  0x00007ff9f58b2e0e in ntdll!KiUserExceptionDispatcher () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#10 0x00007ff9f2dffaec in RaiseException () from
C:\WINDOWS\System32\KernelBase.dll
#11 0x000000006144d151 in libgcc_s_seh-1!_Unwind_RaiseException ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libgcc_s_seh-1.dll
#12 0x000000006fd529eb in libstdc++-6!.cxa_throw () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\libstdc++-6.dll
#13 0x0000000066971fa9 in
liboctinterp-10!_ZN6octave12error_system11throw_errorERNS_19execution_exceptionE
()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#14 0x000000006634cfef in
liboctinterp-10!_ZN6octave12error_system11throw_errorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_S8_RKNS1_4listINS_10frame_infoESaISA_EEE
()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#15 0x000000006634d2ba in
liboctinterp-10!_ZN6octave12error_system7error_1EPKcS2_Pc ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#16 0x000000006634d34d in
liboctinterp-10!_ZN6octave12error_system7error_1EPKcS2_Pc ()
   from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
--Type <RET> for more, q to quit, c to continue without paging--c
#17 0x000000006634d386 in liboctinterp-10!_Z6verrorPKcPc () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#18 0x000000006634d3b2 in liboctinterp-10!_Z5errorPKcz () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#19 0x00000000667f8647 in
liboctinterp-10!_ZN6octave15cdef_object_rep20break_closure_cyclesERKSt10shared_ptrINS_11stack_frameEE
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#20 0x000000006665e9cf in
liboctinterp-10!_ZN6octave20user_fcn_stack_frame20break_closure_cyclesERKSt10shared_ptrINS_11stack_frameEE
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#21 0x00000000662891ea in liboctinterp-10!_ZN6octave10call_stack3popEv () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#22 0x0000000066170373 in
liboctinterp-10!_ZN20octave_user_function4callERN6octave14tree_evaluatorEiRK17octave_value_list
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#23 0x000000006620086d in
liboctinterp-10!_ZN6octave15tree_identifier10evaluate_nERNS_14tree_evaluatorEi
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#24 0x00000000667ff25c in
liboctinterp-10!_ZN6octave15tree_identifier8evaluateERNS_14tree_evaluatorEi ()
from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#25 0x00000000661fb7cc in
liboctinterp-10!_ZN6octave14tree_evaluator15visit_statementERNS_14tree_statementE
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#26 0x00000000661e7cdc in
liboctinterp-10!_ZN6octave14tree_evaluator20visit_statement_listERNS_19tree_statement_listE
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#27 0x00000000661e97aa in
liboctinterp-10!_ZN6octave14tree_evaluator4evalERSt10shared_ptrINS_19tree_statement_listEEb
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#28 0x00000000661f761e in liboctinterp-10!_ZN6octave14tree_evaluator4replEv ()
from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#29 0x00000000664fd4f9 in liboctinterp-10!_ZN6octave11interpreter7executeEv ()
from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctinterp-10.dll
#30 0x0000000000f24670 in
liboctgui-8!_ZN6octave19interpreter_qobject7executeEv () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctgui-8.dll
#31 0x00000000052e17ec in QObject::event(QEvent*) () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#32 0x0000000005e77e73 in QApplicationPrivate::notify_helper(QObject*,
QEvent*) () from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Widgets.dll
#33 0x0000000000f7fd26 in
liboctgui-8!_ZN6octave19octave_qapplication6notifyEP7QObjectP6QEvent () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\liboctgui-8.dll
#34 0x00000000052b47ed in QCoreApplication::notifyInternal2(QObject*, QEvent*)
() from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#35 0x00000000052ba93b in QCoreApplicationPrivate::sendPostedEvents(QObject*,
int, QThreadData*) () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#36 0x000000000530f448 in
QEventDispatcherWin32::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
from C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#37 0x00000000052b3283 in
QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#38 0x00000000050e9140 in QThread::run() () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#39 0x00000000050e9d45 in QThread::setTerminationEnabled(bool) () from
C:\PROGRA~1\GNUOCT~1\OCTAVE~3.0\mingw64\bin\Qt5Core.dll
#40 0x00007ff9f469244d in KERNEL32!BaseThreadInitThunk () from
C:\WINDOWS\System32\kernel32.dll
#41 0x00007ff9f586df78 in ntdll!RtlUserThreadStart () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#42 0x0000000000000000 in ?? ()
Backtrace stopped: previous frame inner to this frame (corrupt stack?)


The last point in our code is
`_ZN6octave12error_system11throw_errorERNS_19execution_exceptionE`. That
demangles to 
`octave::error_system::throw_error(octave::execution_exception&)`.

Are we missing to catch that exception somewhere?

Further down in the backtrace, it looks like the exception is caused somewhere
in
`octave::user_fcn_stack_frame::break_closure_cycles(std::shared_ptr<octave::stack_frame>
const&)` that calls
`octave::cdef_object_rep::break_closure_cycles(std::shared_ptr<octave::stack_frame>
const&)`.
Maybe, this originates from an object array that is created with `obj(2) =
myClass ();` in the function. Maybe, the element at `obj(1)` that should be
implicitly created isn't handled correctly?

I'll try if I can reproduce with a build from the default branch or on Linux.




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?63180>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]