Olive: [CRASH] Deleting Track from Node Editor leads to crash placing content in Timeline

Created on 4 Oct 2020  路  6Comments  路  Source: olive-editor/olive

Commit Hash
Appimage ebd9e271

Platform
openSUSE 15.2

Summary
Olive crashes after placing some media on a deleted Track

Steps to Reproduce

  1. Start Olive
  2. Go to: File > New > Sequence and create a default new sequence
  3. Go to: File > Import... and import an audio file (I'm using an .mp3 file)
  4. In the Node Editor right-click and select Filter > Show All
    Here you'll see the structure of the Sequence

  5. Delete the right Track node
    Now in the Timeline the track Audio 1 has been removed

  6. Drag the imported .mp3 file in the Timeline where the Audio 1 track was placed

Olive crashes consistently.
This happens also with image files (.png) deleting the left Track in step 5 but only as Olive is closed. Did not try with video files, but I suspect the behavior would be the same.

Backtrace

0 olive::SampleBuffer::is_allocated (this=this@entry=0x0) at ../app/codec/samplebuffer.cpp:123

1 0x00000000005a9248 in olive::SampleBuffer::toPackedData (this=0x0) at ../app/codec/samplebuffer.cpp:266

2 0x0000000000660807 in olive::AudioPlaybackCache::WritePCM (this=this@entry=0x2dfd9d0, range=...,

samples=std::shared_ptr<olive::SampleBuffer> (empty) = {...}, job_time=@0x7fffffffd358: 1601822574563)
at /opt/rh/devtoolset-9/root/usr/include/c++/9/bits/shared_ptr_base.h:1020

3 0x0000000000650137 in olive::RenderBackend::AutoCacheAudioRendered (this=0x2e528c0)

at /usr/local/include/QtCore/qmap.h:154

4 0x00007ffff36cbe95 in QMetaObject::activate(QObject, int, int, void*) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

5 0x00007ffff36cc6d2 in QObject::event(QEvent*) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

6 0x00007ffff416a5f2 in QApplicationPrivate::notify_helper(QObject, QEvent) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Widgets.so.5

7 0x00007ffff41736a0 in QApplication::notify(QObject, QEvent) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Widgets.so.5

8 0x00007ffff36a2692 in QCoreApplication::notifyInternal2(QObject, QEvent) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

9 0x00007ffff36a50c8 in QCoreApplicationPrivate::sendPostedEvents(QObject, int, QThreadData) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

10 0x00007ffff36f6173 in ?? () from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

11 0x00007ffff2016464 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0

12 0x00007ffff2016800 in ?? () from /usr/lib64/libglib-2.0.so.0

13 0x00007ffff201688c in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0

14 0x00007ffff36f5811 in QEventDispatcherGlib::processEvents(QFlags) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

15 0x00007ffff36a147b in QEventLoop::exec(QFlags) ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

16 0x00007ffff36a8a6e in QCoreApplication::exec() ()

from /tmp/.mount_Olive-gOV9sf/usr/bin/../lib/libQt5Core.so.5

17 0x000000000055082c in main (argc=, argv=) at ../app/main.cpp:161

Additional Information

Crash

All 6 comments

I can confirm this and think it's possibly linked to issue #1252 in that things go wrong if the samples input on the viewer is not hooked up. It seems that dropping an audio file onto the timeline doesn't hook up the samples properly (at least in this case).

I'm finding adding an image doesn't crash but the texture input of the viewer node doesn't hook up when a image is dropped on the timeline

Interestingly when I close Olive after inputting an image as above I get a crash with the following backtrace:


Backtrace

olive-editor.exe!olive::TrackView::ConnectTrackList(olive::TrackList * list) Line 72
    at C:\Users\Tom\Documents\repos\olive\app\widget\timelinewidget\trackview\trackview.cpp(72)
olive-editor.exe!olive::TrackView::DisconnectTrackList() Line 101
    at C:\Users\Tom\Documents\repos\olive\app\widget\timelinewidget\trackview\trackview.cpp(101)
olive-editor.exe!olive::TimelineWidget::DisconnectNodeInternal(olive::ViewerOutput * n) Line 282
    at C:\Users\Tom\Documents\repos\olive\app\widget\timelinewidget\timelinewidget.cpp(282)
olive-editor.exe!olive::TimeBasedWidget::ConnectViewerNode(olive::ViewerOutput * node) Line 82
    at C:\Users\Tom\Documents\repos\olive\app\widget\timebased\timebased.cpp(82)
olive-editor.exe!olive::TimeBasedPanel::ConnectViewerNode(olive::ViewerOutput * node) Line 138
    at C:\Users\Tom\Documents\repos\olive\app\panel\timebased\timebased.cpp(138)
olive-editor.exe!olive::MainWindow::RemoveTimelinePanel(olive::TimelinePanel * panel) Line 524
    at C:\Users\Tom\Documents\repos\olive\app\window\mainwindow\mainwindow.cpp(524)
olive-editor.exe!olive::MainWindow::CloseSequence(olive::Sequence * sequence) Line 204
    at C:\Users\Tom\Documents\repos\olive\app\window\mainwindow\mainwindow.cpp(204)
olive-editor.exe!olive::MainWindow::ProjectClose(olive::Project * p) Line 343
    at C:\Users\Tom\Documents\repos\olive\app\window\mainwindow\mainwindow.cpp(343)
olive-editor.exe!QtPrivate::FunctorCall<QtPrivate::IndexesList<0>,QtPrivate::List<olive::Project *>,void,void (__cdecl olive::MainWindow::*)(olive::Project *)>::call(void(olive::MainWindow::*)(olive::Project *) f, olive::MainWindow * o, void * * arg) Line 152
    at C:\Users\Tom\Documents\repos\vcpkg\installed\x64-windows\include\QtCore\qobjectdefs_impl.h(152)
olive-editor.exe!QtPrivate::FunctionPointer<void (__cdecl olive::MainWindow::*)(olive::Project *)>::call<QtPrivate::List<olive::Project *>,void>(void(olive::MainWindow::*)(olive::Project *) f, olive::MainWindow * o, void * * arg) Line 186
    at C:\Users\Tom\Documents\repos\vcpkg\installed\x64-windows\include\QtCore\qobjectdefs_impl.h(186)
olive-editor.exe!QtPrivate::QSlotObject<void (__cdecl olive::MainWindow::*)(olive::Project *),QtPrivate::List<olive::Project *>,void>::impl(int which, QtPrivate::QSlotObjectBase * this_, QObject * r, void * * a, bool * ret) Line 419
    at C:\Users\Tom\Documents\repos\vcpkg\installed\x64-windows\include\QtCore\qobjectdefs_impl.h(419)
Qt5Cored.dll!QtPrivate::QSlotObjectBase::call(QObject * r, void * * a) Line 398
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qobjectdefs_impl.h(398)
Qt5Cored.dll!doActivate<0>(QObject * sender, int signal_index, void * * argv) Line 3870
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qobject.cpp(3870)
Qt5Cored.dll!QMetaObject::activate(QObject * sender, const QMetaObject * m, int local_signal_index, void * * argv) Line 3931
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qobject.cpp(3931)
olive-editor.exe!olive::Core::ProjectClosed(olive::Project * _t1) Line 388
    at C:\Users\Tom\Documents\build\olive\x64-Debug\app\olive-editor_autogen\include_Debug\EWIEGA46WW\moc_core.cpp(388)
olive-editor.exe!olive::Core::CloseProject(std::shared_ptr<olive::Project> p, bool auto_open_new, olive::Core::CloseProjectBehavior & confirm_behavior) Line 1111
    at C:\Users\Tom\Documents\repos\olive\app\core.cpp(1111)
olive-editor.exe!olive::Core::CloseAllProjects(bool auto_open_new) Line 1151
    at C:\Users\Tom\Documents\repos\olive\app\core.cpp(1151)
olive-editor.exe!olive::MainWindow::closeEvent(QCloseEvent * e) Line 397
    at C:\Users\Tom\Documents\repos\olive\app\window\mainwindow\mainwindow.cpp(397)
Qt5Widgetsd.dll!QWidget::event(QEvent * event) Line 8829
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qwidget.cpp(8829)
Qt5Widgetsd.dll!QMainWindow::event(QEvent * event) Line 1342
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\widgets\qmainwindow.cpp(1342)
Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3685
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qapplication.cpp(3685)
Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3635
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qapplication.cpp(3635)
Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1075
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qcoreapplication.cpp(1075)
Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 1483
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qcoreapplication.cpp(1483)
Qt5Widgetsd.dll!QWidgetPrivate::close_helper(QWidgetPrivate::CloseMode mode) Line 8252
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qwidget.cpp(8252)
Qt5Widgetsd.dll!QWidgetWindow::handleCloseEvent(QCloseEvent * event) Line 827
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qwidgetwindow.cpp(827)
Qt5Widgetsd.dll!QWidgetWindow::event(QEvent * event) Line 254
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qwidgetwindow.cpp(254)
Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3685
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qapplication.cpp(3685)
Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3025
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\widgets\kernel\qapplication.cpp(3025)
Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1075
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qcoreapplication.cpp(1075)
Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 1483
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qcoreapplication.cpp(1483)
Qt5Guid.dll!QGuiApplicationPrivate::processCloseEvent(QWindowSystemInterfacePrivate::CloseEvent * e) Line 2562
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\gui\kernel\qguiapplication.cpp(2562)
Qt5Guid.dll!QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent * e) Line 1981
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\gui\kernel\qguiapplication.cpp(1981)
Qt5Guid.dll!QWindowSystemInterface::sendWindowSystemEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 1176
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\gui\kernel\qwindowsysteminterface.cpp(1176)
qwindowsd.dll!000007feaae3ad12()
Qt5Cored.dll!QEventDispatcherWin32::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 525
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qeventdispatcher_win.cpp(525)
qwindowsd.dll!000007feaae3acc4()
Qt5Cored.dll!QEventLoop::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 139
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qeventloop.cpp(139)
Qt5Cored.dll!QEventLoop::exec(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 225
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qeventloop.cpp(225)
Qt5Cored.dll!QCoreApplication::exec() Line 1383
    at C:\Users\Tom\Documents\repos\vcpkg\buildtrees\qt5-base\src\5.14.2-8b6659c0d6\src\corelib\kernel\qcoreapplication.cpp(1383)
olive-editor.exe!main(int argc, char * * argv) Line 161
    at C:\Users\Tom\Documents\repos\olive\app\main.cpp(161)
olive-editor.exe!invoke_main() Line 79
    at D:\agent\_work\9\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(79)
olive-editor.exe!__scrt_common_main_seh() Line 288
    at D:\agent\_work\9\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(288)
olive-editor.exe!__scrt_common_main() Line 331
    at D:\agent\_work\9\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(331)
olive-editor.exe!mainCRTStartup() Line 17
    at D:\agent\_work\9\s\src\vctools\crt\vcstartup\src\startup\exe_main.cpp(17)
kernel32.dll!BaseThreadInitThunk
()
ntdll.dll!RtlUserThreadStart
()

Error:
Exception thrown: read access violation. item->**** was 0xFFFFFFFFFFFFFFE7.

So I think the issue here is that when a track node is delete in the node editor it doesn't get removed from the track list in TrackView so TrackView ends up trying to delete a non existent TrackViewItem. I'm not really sure how to make this happen though, presumably something will need to be added to NodeViewUndo

I think this is mostly fixed by 221e0efb9653e768d75bd3e55274d1ef4a841a0a and #1262 although Texture and Samples never get properly hooked up automatically

Tested with cf07e52b and cannot reproduce the issue.
Closing as fixed!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Chadt54 picture Chadt54  路  35Comments

Efenstor picture Efenstor  路  22Comments

Symbian9 picture Symbian9  路  27Comments

zakaria-chahboun picture zakaria-chahboun  路  21Comments

winfr34k picture winfr34k  路  20Comments