Shotcut segfaults on loading any saved mlt [since kernel update on Mint systems?]

I’m using the Portable Tarfile version of the latest Shotcut (20.04.12) on the most recent Linux Mint.

Recently (within the last day or two), the Shotcut application has become unusable - crashing on trying to open any previously saved project. Whilst Shotcut hasn’t been updated, obviously a live system gets many updates to components that Shotcut depends on - although the only big updates recently have been new kernels (the current kernel is in Mint).

Running Shotcut in a terminal to get all the output, I see some interesting things:

Firstly (non-fatal errors):
[Warning] <> file:///home/aoanla/Desktop/newShotcut/Shotcut/ TypeError: Cannot read property of null

Then (on trying to open a saved project which has not changed since it was last successfully open and saved):

[Debug ] KeyframesDock::load begin
[Debug ] MainWindow::open “/home/aoanla/Videos/Argentina/Argentina.mlt”
[Info ] MainWindow::showStatusMessage “Opening /home/aoanla/Videos/Argentina/Argentina.mlt”
[Debug ] MltXmlChecker::check begin
[Info ] MltXmlChecker::check decimal point ‘.’
[Debug ] MltXmlChecker::check end
[Info ] MainWindow::open decimal point ‘.’
[Debug ] Mlt::Controller::setPreviewScale 1280 x 720
[Debug ] Mlt::Controller::setProjectFolder project folder “/home/aoanla/Videos/Argentina”
[Debug ] MainWindow::setAudioChannels 2
[Debug ] Mlt::Controller::setAudioChannels 2
Segmentation fault

the same segmentation fault happens for all other .mlt projects I have on this system.

Grabbing a core dump of Shotcut when it crashes gives the following stacktrace, which looks to me like it’s trying to use a function pointer which isn’t initialised?:

Thread 1 “shotcut” received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0 0x0000000000000000 in ()
#1 0x00007f158adb2d39 in QSGBatchRenderer::Renderer::renderBatches() ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#2 0x00007f158adb8804 in QSGBatchRenderer::Renderer::render() ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#3 0x00007f158ada9032 in QSGRenderer::renderScene(QSGBindable const&) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#4 0x00007f158ada950b in QSGRenderer::renderScene(unsigned int) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#5 0x00007f158ade4aae in QSGDefaultRenderContext::renderNextFrame(QSGRenderer*, unsigned int) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#6 0x00007f158ae3fae4 in QQuickWindowPrivate::renderSceneGraph(QSize const&) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#7 0x00007f158aefb728 in QQuickRenderControl::render() ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#8 0x00007f158bcce2b0 in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#9 0x00007f158bcd2189 in QQuickWidget::event(QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#10 0x00007f158b1f764c in QApplicationPrivate::notify_helper(QObject*, QEvent*)
at /home/aoanla/Desktop/newShotcut/Shotcut/
#11 0x00007f158b1ff057 in QApplication::notify(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#12 0x00007f1589dd6328 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#13 0x00007f158b25049b in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#14 0x00007f158b2504d4 in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#15 0x00007f158b25053b in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#16 0x00007f1589e027e9 in QMetaObject::activate(QObject*, int, int, void**) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#17 0x00007f158a804b5f in QWindow::screenChanged(QScreen*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#18 0x00007f158a805303 in QWindowPrivate::emitScreenChangedRecursion(QScreen*) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#19 0x00007f158a80c97e in QWindowPrivate::setTopLevelScreen(QScreen*, bool) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#20 0x00007f158b22b070 in QWidgetPrivate::create_sys(unsigned long long, bool, bool) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#21 0x00007f158b22b3db in QWidget::create(unsigned long long, bool, bool) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#22 0x00007f158b236099 in QWidget::setVisible(bool) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#23 0x00000000004766af in ()
#24 0x00000000005e73de in ()
#25 0x00007f1589e027e9 in QMetaObject::activate(QObject*, int, int, void**) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#26 0x0000000000460a48 in ()
#27 0x000000000047ae82 in ()
#28 0x00000000005e2b03 in ()
#29 0x00000000005ff6b9 in ()
#30 0x00000000005ff925 in ()
#31 0x00007f1589e02954 in QMetaObject::activate(QObject*, int, int, void**) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#32 0x00007f158b440225 in QAbstractItemView::clicked(QModelIndex const&) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#33 0x00007f158b443603 in QAbstractItemView::mouseReleaseEvent(QMouseEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#34 0x00007f158b48576e in QListView::mouseReleaseEvent(QMouseEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#35 0x00007f158b236678 in QWidget::event(QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#36 0x00007f158b2de3ee in QFrame::event(QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#37 0x00007f158b44cf03 in QAbstractItemView::viewportEvent(QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#38 0x00007f1589dd6092 in QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#39 0x00007f158b1f7625 in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#40 0x00007f158b1ffc7b in QApplication::notify(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#41 0x00007f1589dd6328 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#42 0x00007f158b1fe61f in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer&, bool) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#43 0x00007f158b2509e6 in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#44 0x00007f158b253443 in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#45 0x00007f158b1f764c in QApplicationPrivate::notify_helper(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#46 0x00007f158b1ff057 in QApplication::notify(QObject*, QEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#47 0x00007f1589dd6328 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#48 0x00007f158a800820 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#49 0x00007f158a802755 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#50 0x00007f158a7dba2b in QWindowSystemInterface::sendWindowSystemEvents(QFlagsQEventLoop::ProcessEventsFlag) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#51 0x00007f157e3748f0 in ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#52 0x00007f1585236417 in g_main_context_dispatch ()
at /usr/lib/x86_64-linux-gnu/
#53 0x00007f1585236650 in () at /usr/lib/x86_64-linux-gnu/
#54 0x00007f15852366dc in g_main_context_iteration ()
at /usr/lib/x86_64-linux-gnu/
#55 0x00007f1589e2bc1f in QEventDispatcherGlib::processEvents(QFlagsQEventLoop::ProcessEventsFlag) ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#56 0x00007f1589dd435a in QEventLoop::exec(QFlagsQEventLoop::ProcessEventsFlag) () at /home/aoanla/Desktop/newShotcut/Shotcut/
#57 0x00007f1589ddd2f4 in QCoreApplication::exec() ()
at /home/aoanla/Desktop/newShotcut/Shotcut/
#58 0x0000000000459e9c in main ()

It looks like OpenGL is broken on your system.

Nope, lots of OpenGL applications still run (I just checked with glxgears, and it appropriately loads the nvidia driver and runs fine).

the bit of the Shotcut log concerning OpenGL initialisation reads:

[Debug ] Mlt::GLWidget::initializeGL begin
[Info ] Mlt::GLWidget::initializeGL OpenGL vendor “NVIDIA Corporation”
[Info ] Mlt::GLWidget::initializeGL OpenGL renderer “GeForce GTX 1660 Ti/PCIe/SSE2”
[Info ] Mlt::GLWidget::initializeGL OpenGL threaded? true
[Info ] Mlt::GLWidget::initializeGL OpenGL ES? false
[Debug ] Mlt::GLWidget::initializeGL end

Do you have multiple displays?
Try moving your Shotcut configuration file to prevent it from loading and make it load defaults.

I do have multiple displays - but this has never broken Shotcut before.

[On that topic, though - Shotcut does deal very badly with powersaving on multiple displays, and it often hangs on trying to close it if the system it is running on has ever gone into powersaving since it was started.]

Moving the configuration file does fix the segfault, thanks , although the log now spams lots of
“[Warning] <> file:///home/aoanla/Desktop/newShotcut/Shotcut/ Unable to assign [undefined] to QString” whilst it loads the file, which I am not sure is a problem or not.

Those QML warnings are typical

hm, trying to close Shotcut after opening the file, it’s just decided to hang and not close. The log shows
[Debug ] MainWindow::closeEvent begin

but the GUI has frozen (for at least a minute now, with no cpu load in top) . Is it safe to forcibly terminate, or should I wait and hope it does the right thing?

(Attaching GDB to the running process, it looks like it’s stuck in some futex dead or livelock in QThread)

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.