ccherrett / oom

The Open Octave Project exists to provide professional level orchestral midi orchestration tools.
http://www.openoctave.org
GNU General Public License v2.0
82 stars 19 forks source link

Track movement bug #53

Closed alekz49 closed 12 years ago

alekz49 commented 12 years ago

When trying to move a track up in the track order, OOMidi-2011 segfaults. This was tested with 187 tracks, a new midi track was added, and moving it produced a crash.

ccherrett commented 12 years ago

Program received signal SIGSEGV, Segmentation fault. 0x00007ffff0375431 in QString::operator== (this=0x30c7ba8, other=...) at tools/qstring.cpp:2150 2150 tools/qstring.cpp: No such file or directory. in tools/qstring.cpp (gdb) bt

0 0x00007ffff0375431 in QString::operator== (this=0x30c7ba8, other=...) at tools/qstring.cpp:2150

1 0x000000000054b8de in qStringComparisonHelper (s1=..., s2=0xa136db "Master") at /usr/include/qt4/QtCore/qstring.h:922

2 0x000000000054b90f in QString::operator== (this=0x30c7ba8, s=0xa136db "Master") at /usr/include/qt4/QtCore/qstring.h:925

3 0x000000000073f7b7 in HeaderList::moveSelectedTrack (this=0x24a0590, dir=-1)

at /home/chris/workspace/git-projects/oom/oom/Composer/HeaderList.cpp:499

4 0x0000000000743116 in HeaderList::qt_metacall (this=0x24a0590, _c=QMetaObject::InvokeMetaMethod, _id=14, _a=0x7fffffffb960)

at /home/chris/workspace/git-projects/oom/dbuild/oom/Composer/moc_HeaderList.cxx:118

5 0x00007ffff042bad1 in QMetaObject::activate (sender=0x24a6160, m=, local_signal_index=,

argv=0x18) at kernel/qobject.cpp:3278

6 0x0000000000742bf4 in ComposerCanvas::moveSelectedTracks (this=0x24a6160, _t1=-1)

at /home/chris/workspace/git-projects/oom/dbuild/oom/Composer/moc_ComposerCanvas.cxx:198

7 0x0000000000727684 in ComposerCanvas::keyPress (this=0x24a6160, event=0x7fffffffc9e0)

at /home/chris/workspace/git-projects/oom/oom/Composer/ComposerCanvas.cpp:2188

8 0x0000000000578840 in ComposerCanvas::redirKeypress (this=0x24a6160, e=0x7fffffffc9e0)

at /home/chris/workspace/git-projects/oom/dbuild/oom/Composer/../../../oom/Composer/ComposerCanvas.h:208

9 0x000000000074287f in ComposerCanvas::qt_metacall (this=0x24a6160, _c=QMetaObject::InvokeMetaMethod, _id=14, _a=0x7fffffffc110)

at /home/chris/workspace/git-projects/oom/dbuild/oom/Composer/moc_ComposerCanvas.cxx:112

10 0x00007ffff042bad1 in QMetaObject::activate (sender=0x24a0590, m=, local_signal_index=,

argv=0x18) at kernel/qobject.cpp:3278

11 0x0000000000743223 in HeaderList::keyPressExt (this=0x24a0590, _t1=0x7fffffffc9e0)

at /home/chris/workspace/git-projects/oom/dbuild/oom/Composer/moc_HeaderList.cxx:141

12 0x0000000000740729 in HeaderList::keyPressEvent (this=0x24a0590, e=0x7fffffffc9e0)

at /home/chris/workspace/git-projects/oom/oom/Composer/HeaderList.cpp:676

13 0x00007ffff151e569 in QWidget::event (this=0x24a0590, event=0x7fffffffc9e0) at kernel/qwidget.cpp:8294

14 0x00007ffff1891148 in QFrame::event (this=0x24a0590, e=0x7fffffffc9e0) at widgets/qframe.cpp:557

15 0x00007ffff14d1a75 in QApplicationPrivate::notify_helper (this=0x1577210, receiver=0x24a0590, e=0x7fffffffc9e0)

at kernel/qapplication.cpp:4462

16 0x00007ffff14d7e72 in QApplication::notify (this=, receiver=0x24a0590, e=0x7fffffffc9e0)

at kernel/qapplication.cpp:3921

17 0x000000000054be2d in OOMidiApplication::notify (this=0x7fffffffd9b0, receiver=0x24a0590, event=0x7fffffffc9e0)

at /home/chris/workspace/git-projects/oom/oom/main.cpp:146

18 0x00007ffff0415e4e in QCoreApplication::notifyInternal (this=0x7fffffffd9b0, receiver=0x24a0590, event=0x7fffffffc9e0)

at kernel/qcoreapplication.cpp:731

19 0x00007ffff156f692 in QKeyMapper::sendKeyEvent (keyWidget=0x24a0590, grab=, type=QEvent::KeyPress, code=16777237,

modifiers=<value optimized out>, text=..., autorepeat=false, count=1, nativeScanCode=116, nativeVirtualKey=65364, nativeModifiers=28)
at kernel/qkeymapper_x11.cpp:1866

20 0x00007ffff157197e in QKeyMapperPrivate::translateKeyEvent (this=0x7fffffffcec0, keyWidget=0x24a0590, event=,

grab=16) at kernel/qkeymapper_x11.cpp:1836

21 0x00007ffff154cf2c in QApplication::x11ProcessEvent (this=, event=0x7fffffffd590)

at kernel/qapplication_x11.cpp:3480

22 0x00007ffff1574b09 in x11EventSourceDispatch (s=0x157b620, callback=, user_data=)

at kernel/qguieventdispatcher_glib.cpp:146

23 0x00007ffff488a405 in g_main_dispatch (context=0x153b9f0) at gmain.c:2441

24 g_main_context_dispatch (context=0x153b9f0) at gmain.c:3011

25 0x00007ffff488d9df in g_main_context_iterate (context=0x153b9f0, block=, dispatch=,

self=<value optimized out>) at gmain.c:3089

26 0x00007ffff488daf8 in g_main_context_iteration (context=0x153b9f0, may_block=1) at gmain.c:3152

27 0x00007ffff043def2 in QEventDispatcherGlib::processEvents (this=0x14ff200, flags=)

at kernel/qeventdispatcher_glib.cpp:422

28 0x00007ffff1574562 in QGuiEventDispatcherGlib::processEvents (this=0x30c7ba8, flags=)

at kernel/qguieventdispatcher_glib.cpp:204

29 0x00007ffff0414e82 in QEventLoop::processEvents (this=, flags=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece or DW_OP_bit_piece.

) at kernel/qeventloop.cpp:149

30 0x00007ffff04151e1 in QEventLoop::exec (this=0x7fffffffd8b0, flags=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece or DW_OP_bit_piece.

) at kernel/qeventloop.cpp:201

31 0x00007ffff0418c57 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1008

32 0x000000000054b31d in main (argc=1, argv=0x7fffffffdd68) at /home/chris/workspace/git-projects/oom/oom/main.cpp:567

ccherrett commented 12 years ago

it happens when moving a track beyond the existing list kills oomidi. Could compare track id instead of name? This one will be fixed soon

ccherrett commented 12 years ago

Fixed!

Checking for the end of an iterator without safeguards is a problem :)