Segfault in OstcFirmwareCheck::checkLatest

Gaetan Bisson bisson at archlinux.org
Wed Jan 8 17:55:26 PST 2020


Dear list,

I just rebuilt subsurface from current git master and am getting a
segfault when downloading dives from my OSTC3. The problem appears to be
in OstcFirmwareCheck::checkLatest. I'm attaching the full backtrace of
the crash. I'll investigate more later unless someone beats me to it.

Happy new year!

-- 
Gaetan
-------------- next part --------------
ASSERT failure in QList<T>::operator[]: "index out of range", file /usr/include/qt/QtCore/qlist.h, line 579

Thread 1 "subsurface" received signal SIGABRT, Aborted.
0x00007fffefd1bf25 in raise () from /usr/lib/libc.so.6
(gdb) bt full
#0  0x00007fffefd1bf25 in raise () at /usr/lib/libc.so.6
#1  0x00007fffefd05897 in abort () at /usr/lib/libc.so.6
#2  0x0000555555664175 in messageHandler(QtMsgType, QMessageLogContext const&, QString const&) (type=<optimized out>, msg=...) at /opt/arch/aur/subsurface-git/src/subsurface/subsurface-desktop-main.cpp:241
        localMsg = {d = 0x55555c948930}
#3  0x00007ffff02b4ad8 in  () at /usr/lib/libQt5Core.so.5
#4  0x00007ffff02b4bea in  () at /usr/lib/libQt5Core.so.5
#5  0x00007ffff0281952 in QMessageLogger::fatal(char const*, ...) const () at /usr/lib/libQt5Core.so.5
#6  0x00007ffff0280d52 in  () at /usr/lib/libQt5Core.so.5
#7  0x000055555566bd99 in QList<QString>::operator[](int) (i=<optimized out>, this=<optimized out>) at /usr/include/qt/QtCore/qstringlist.h:111
        X = <optimized out>
        Y = <optimized out>
        Z = <optimized out>
        beta = <optimized out>
        firmwareOnDevice = 775
        firmwareOnDeviceString = {static null = {<No data fields>}, d = 0x555557300900}
        fwParts =
              {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x555557302ac0}, d = 0x555557302ac0}}, <No data fields>}
        latestFirmwareAvailableNumber = <optimized out>
#8  0x000055555566bd99 in OstcFirmwareCheck::checkLatest(QWidget*, dc_user_device_t*) (this=this at entry=0x7fffb4008030, _parent=_parent at entry=0x7fffffffcd90, data=<optimized out>) at /opt/arch/aur/subsurface-git/src/subsurface/desktop-widgets/configuredivecomputerdialog.cpp:290
        X = <optimized out>
        Y = <optimized out>
        Z = <optimized out>
        beta = <optimized out>
        firmwareOnDevice = 775
        firmwareOnDeviceString = {static null = {<No data fields>}, d = 0x555557300900}
        fwParts =
              {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x555557302ac0}, d = 0x555557302ac0}}, <No data fields>}
        latestFirmwareAvailableNumber = <optimized out>
#9  0x0000555555759726 in DownloadFromDCWidget::on_ok_clicked() (this=0x7fffffffcd90) at /opt/arch/aur/subsurface-git/src/subsurface/desktop-widgets/downloadfromdivecomputer.cpp:550
        tables = {first = {nr = 0, allocated = 48, dives = 0x7fffbc001c00}, second = {nr = 0, allocated = 0, dive_sites = 0x0}}
#10 0x00005555556e55b4 in DownloadFromDCWidget::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=0x7fffffffbfa0)
    at /opt/arch/aur/subsurface-git/src/subsurface/build/desktop-widgets/subsurface_interface_autogen/EWIEGA46WW/moc_downloadfromdivecomputer.cpp:152
        _t = <optimized out>
#11 0x00005555556e7813 in DownloadFromDCWidget::qt_metacall(QMetaObject::Call, int, void**) (this=0x7fffffffcd90, _c=QMetaObject::InvokeMetaMethod, _id=1, _a=0x7fffffffbfa0)
    at /opt/arch/aur/subsurface-git/src/subsurface/build/desktop-widgets/subsurface_interface_autogen/EWIEGA46WW/moc_downloadfromdivecomputer.cpp:208
#12 0x00007ffff04cd082 in  () at /usr/lib/libQt5Core.so.5
#13 0x00007ffff1d74dc3 in QAbstractButton::clicked(bool) () at /usr/lib/libQt5Widgets.so.5
#14 0x00007ffff1d74fec in  () at /usr/lib/libQt5Widgets.so.5
#15 0x00007ffff1d763f2 in  () at /usr/lib/libQt5Widgets.so.5
#16 0x00007ffff1d765b6 in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () at /usr/lib/libQt5Widgets.so.5
#17 0x00007ffff1cbe7e6 in QWidget::event(QEvent*) () at /usr/lib/libQt5Widgets.so.5
#18 0x00007ffff1c7a472 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#19 0x00007ffff1c83ed8 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#20 0x00007ffff0497832 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib/libQt5Core.so.5
#21 0x00007ffff1c82ff6 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) () at /usr/lib/libQt5Widgets.so.5
#22 0x00007ffff1cd9f91 in  () at /usr/lib/libQt5Widgets.so.5
#23 0x00007ffff1cdcf14 in  () at /usr/lib/libQt5Widgets.so.5
#24 0x00007ffff1c7a472 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#25 0x00007ffff1c83c89 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#26 0x00007ffff0497832 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib/libQt5Core.so.5
#27 0x00007ffff0fac2c4 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () at /usr/lib/libQt5Gui.so.5
#28 0x00007ffff0fad9d6 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) () at /usr/lib/libQt5Gui.so.5
#29 0x00007ffff0f86c2c in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Gui.so.5
#30 0x00007fffec65ca2c in  () at /usr/lib/libQt5XcbQpa.so.5
#31 0x00007fffeebd539e in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
#32 0x00007fffeebd71b1 in  () at /usr/lib/libglib-2.0.so.0
#33 0x00007fffeebd71f1 in g_main_context_iteration () at /usr/lib/libglib-2.0.so.0
#34 0x00007ffff04efcc0 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#35 0x00007ffff049639c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#36 0x00007ffff1e8868e in QDialog::exec() () at /usr/lib/libQt5Widgets.so.5
#37 0x00005555556942b8 in MainWindow::on_actionDownloadDC_triggered() (this=<optimized out>) at /opt/arch/aur/subsurface-git/src/subsurface/desktop-widgets/mainwindow.cpp:766
        dlg =
          {<QDialog> = {<No data fields>}, static staticMetaObject = {d = {superdata = {direct = 0x7ffff21a4220 <QDialog::staticMetaObject>}, stringdata = 0x5555559f6820 <qt_meta_stringdata_DownloadFromDCWidget>, data = 0x5555559f65a0 <qt_meta_data_DownloadFromDCWidget>, static_metacall = 0x5555556e5430 <DownloadFromDCWidget::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, vendorModel = <incomplete type>, productModel = <incomplete type>, ui = {<Ui_DownloadFromDiveComputer> = {verticalLayout_3 = 0x55555c92f080, horizontalLayout = 0x55555c9443d0, verticalLayout_2 = 0x55555c948e90, choicesLayout = 0x55555a9d0b20, forceDownload = 0x5555573018b0, label_2 = 0x555556395400, vendor = 0x55555a763560, preferDownloaded = 0x55555c944440, logToFile = 0x55555c938e40, device = 0x55555c92f290, bluetoothMode = 0x55555c9407d0, chooseBluetoothDevice = 0x55555c9415c0, search = 0x55555c945920, chooseDumpFile = 0x55555c945ef0, label_3 = 0x55555c946640, chooseLogFile = 0x55555c9469c0, label = 0x55555c947000, createNewTrip = 0x55555c947380, dumpToFile = 0x55555c9474a0, product = 0x55555c9476d0, DCGrid = 0x55555c947a00, DC1 = 0x55555c948520, DC2 = 0x55555c948660, DC3 = 0x55555c9a0cb0, DC4 = 0x55555c9a0e10, downloadCancelRetryLayout = 0x55555c9a0f80, horizontalSpacer_2 = 0x55555c9a1050, downloadCancelRetryButton = 0x55555c9a10b0, progressBar = 0x55555c9a11f0, progressText = 0x55555c9a1390, aboveOKCancelSpacer = 0x55555c9a0f50, verticalLayout = 0x55555c9a1780, labelSelectAllNoneLayout = 0x55555c9a1920, downloadedDivesLabel = 0x55555c9a1ae0, selectAllButton = 0x55555c9a1e60, unselectAllButton = 0x55555c9a21a0, downloadedView = 0x55555c9a2730, buttonBoxLayout = 0x55555c9a9360, horizontalSpacer = 0x55555c9a9390, ok = 0x55555c9a9d00, cancel = 0x55555c9aa030}, <No data fields>}, downloading = false, previousLast = 0, timer = 0x7fffdc006cd0, dumpWarningShown = false, ostcFirmwareCheck = std::unique_ptr<class OstcFirmwareCheck> = {get() = 0x7fffb4008030}, diveImportedModel = 0x55555c94a2e0, btDeviceSelectionDialog = 0x0, btd = 0x0, currentState = DownloadFromDCWidget::DONE}
#38 0x00005555556e58a0 in MainWindow::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>)
    at /opt/arch/aur/subsurface-git/src/subsurface/build/desktop-widgets/subsurface_interface_autogen/EWIEGA46WW/moc_mainwindow.cpp:334
        _t = <optimized out>
#39 0x00005555556e9c93 in MainWindow::qt_metacall(QMetaObject::Call, int, void**) (this=0x555555ddc450, _c=QMetaObject::InvokeMetaMethod, _id=14, _a=0x7fffffffd110)
    at /opt/arch/aur/subsurface-git/src/subsurface/build/desktop-widgets/subsurface_interface_autogen/EWIEGA46WW/moc_mainwindow.cpp:429
#40 0x00007ffff04cd082 in  () at /usr/lib/libQt5Core.so.5
#41 0x00007ffff1c73f23 in QAction::triggered(bool) () at /usr/lib/libQt5Widgets.so.5
#42 0x00007ffff1c7660c in QAction::activate(QAction::ActionEvent) () at /usr/lib/libQt5Widgets.so.5
#43 0x00007ffff1e03ab3 in  () at /usr/lib/libQt5Widgets.so.5
#44 0x00007ffff1e0b36c in  () at /usr/lib/libQt5Widgets.so.5
#45 0x00007ffff1e0c3b3 in QMenu::mouseReleaseEvent(QMouseEvent*) () at /usr/lib/libQt5Widgets.so.5
#46 0x00007ffff1cbe7e6 in QWidget::event(QEvent*) () at /usr/lib/libQt5Widgets.so.5
#47 0x00007ffff1e0ea0c in QMenu::event(QEvent*) () at /usr/lib/libQt5Widgets.so.5
#48 0x00007ffff1c7a472 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#49 0x00007ffff1c83ed8 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#50 0x00007ffff0497832 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib/libQt5Core.so.5
#51 0x00007ffff1c82ff6 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool, bool) () at /usr/lib/libQt5Widgets.so.5
#52 0x00007ffff1cda928 in  () at /usr/lib/libQt5Widgets.so.5
#53 0x00007ffff1cdcf14 in  () at /usr/lib/libQt5Widgets.so.5
#54 0x00007ffff1c7a472 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#55 0x00007ffff1c83c89 in QApplication::notify(QObject*, QEvent*) () at /usr/lib/libQt5Widgets.so.5
#56 0x00007ffff0497832 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib/libQt5Core.so.5
#57 0x00007ffff0fac2c4 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () at /usr/lib/libQt5Gui.so.5
#58 0x00007ffff0fad9d6 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) () at /usr/lib/libQt5Gui.so.5
#59 0x00007ffff0f86c2c in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Gui.so.5
#60 0x00007fffec65ca2c in  () at /usr/lib/libQt5XcbQpa.so.5
#61 0x00007fffeebd539e in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
#62 0x00007fffeebd71b1 in  () at /usr/lib/libglib-2.0.so.0
#63 0x00007fffeebd71f1 in g_main_context_iteration () at /usr/lib/libglib-2.0.so.0
#64 0x00007ffff04efcc0 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#65 0x00007ffff049639c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib/libQt5Core.so.5
#66 0x00007ffff049e3a6 in QCoreApplication::exec() () at /usr/lib/libQt5Core.so.5
#67 0x00005555556889d4 in main(int, char**) (argc=<optimized out>, argv=<optimized out>) at /opt/arch/aur/subsurface-git/src/subsurface/subsurface-desktop-main.cpp:117
        i = <optimized out>
        no_filenames = <optimized out>
        app = std::unique_ptr<class QApplication> = {get() = 0x555555b10670}
        files = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x55555ae826b0}, d = 0x55555ae826b0}}, <No data fields>}
        importedFiles = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x7ffff0580310 <QListData::shared_null>}, d = 0x7ffff0580310 <QListData::shared_null>}}, <No data fields>}
        arguments = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, d = 0x555555b7d090}, d = 0x555555b7d090}}, <No data fields>}
        default_directory = 0x555555b7d0b0 "/home/bisson/.subsurface"
        default_filename = 0x555555b7d100 "/home/bisson/.subsurface/bisson.xml"
        m = 0x555555ddc450
        __PRETTY_FUNCTION__ = "int main(int, char**)"


More information about the subsurface mailing list