I'm compiling myself the develop version, this happens since commit f520a0f2
I can open a database or create a new one. But when I want to edit an existing entry or create a new one, I get the following output in the terminal:
qt5ct: using qt5ct plugin
qt5ct: D-Bus global menu: no
[1] 19976 segmentation fault (core dumped) src/keepassxc
When compiling with tests and gui tests, running make test with GUI tests enabled the tests crash on 27:
27/28 Test #27: testgui ..........................***Exception: Child aborted 5.58 sec
I cannot use keepassxc.
KeePassXC - Version 2.2.4
Revision: f520a0f
Libraries:
OS: Arch Linux
Architecture: x86_64
Kernel: linux 4.14.13-1-ARCH
Enabled Extensions:
cmake -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_BINDIR=/usr/bin \
-DCMAKE_VERBOSE_MAKEFILE=OFF \
-DWITH_GUI_TESTS=ON \
-DWITH_TESTS=ON \
-DWITH_XC_AUTOTYPE=ON \
-DWITH_XC_HTTP=OFF \
-DWITH_XC_NETWORKING=ON \
-DWITH_XC_YUBIKEY=OFF \
-DWITH_XC_BROWSER=ON \
-DWITH_XC_SSHAGENT=OFF \
-DCMAKE_BUILD_TYPE=Release ..
coredumpctl dump gives the following output:
PID: 19976 (keepassxc)
UID: 1000 (redacted)
GID: 1000 (redacted)
Signal: 11 (SEGV)
Timestamp: Sat 2018-01-20 13:17:01 CET (4min 8s ago)
Command Line: src/keepassxc
Executable: /home/redacted/.sources/keepassxc/build/src/keepassxc
Control Group: /user.slice/user-1000.slice/session-c2.scope
Unit: session-c2.scope
Slice: user-1000.slice
Session: c2
Owner UID: 1000 (redacted)
Boot ID: 8a570a63045d451a963ff1a70db8a12e
Machine ID: 5a3d1d090af943a8a204286c2369b26e
Hostname: redacted
Storage: /var/lib/systemd/coredump/core.keepassxc.1000.8a570a63045d451a963ff1a70db8a12e.19976.1516450621000000.lz4
Message: Process 19976 (keepassxc) of user 1000 dumped core.
Stack trace of thread 19976:
#0 0x00007ff6f61d6f4a _ZN16QCoreApplication9postEventEP7QObjectP6QEventi (libQt5Core.so.5)
#1 0x000055d52a435c0a n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#2 0x000055d52a43509a n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#3 0x000055d52a434d7e n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#4 0x000055d52a45131d n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#5 0x000055d52a4505bf n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#6 0x000055d52a426189 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#7 0x000055d52a423fb4 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#8 0x000055d52a3bd071 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#9 0x00007ff6f6203ee6 _ZN11QMetaObject8activateEP7QObjectiiPPv (libQt5Core.so.5)
#10 0x00007ff6f790d383 _ZN7QAction9triggeredEb (libQt5Widgets.so.5)
#11 0x00007ff6f790fc06 _ZN7QAction8activateENS_11ActionEventE (libQt5Widgets.so.5)
#12 0x00007ff6f7a0ac0c n/a (libQt5Widgets.so.5)
#13 0x00007ff6f7a0ae7e _ZN15QAbstractButton17mouseReleaseEventEP11QMouseEvent (libQt5Widgets.so.5)
#14 0x00007ff6f7af0deb _ZN11QToolButton17mouseReleaseEventEP11QMouseEvent (libQt5Widgets.so.5)
#15 0x00007ff6f7953e38 _ZN7QWidget5eventEP6QEvent (libQt5Widgets.so.5)
#16 0x00007ff6f7af0e85 _ZN11QToolButton5eventEP6QEvent (libQt5Widgets.so.5)
#17 0x00007ff6f7913e3c _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5)
#18 0x00007ff6f791bd91 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5)
#19 0x00007ff6f61d36c0 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5)
#20 0x00007ff6f791ad1a _ZN19QApplicationPrivate14sendMouseEventEP7QWidgetP11QMouseEventS1_S1_PS1_R8QPointerIS0_Eb (libQt5Widgets.so.5)
#21 0x00007ff6f796f289 n/a (libQt5Widgets.so.5)
#22 0x00007ff6f79719a0 n/a (libQt5Widgets.so.5)
#23 0x00007ff6f7913e3c _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5)
#24 0x00007ff6f791b816 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5)
#25 0x00007ff6f61d36c0 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5)
#26 0x00007ff6f710a634 _ZN22QGuiApplicationPrivate17processMouseEventEPN29QWindowSystemInterfacePrivate10MouseEventE (libQt5Gui.so.5)
#27 0x00007ff6f710c186 _ZN22QGuiApplicationPrivate24processWindowSystemEventEPN29QWindowSystemInterfacePrivate17WindowSystemEventE (libQt5Gui.so.5)
#28 0x00007ff6f70e3bbc _ZN22QWindowSystemInterface22sendWindowSystemEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Gui.so.5)
#29 0x00007ff6ee5bf2fd n/a (libQt5XcbQpa.so.5)
#30 0x00007ff6f61d1d0b _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5)
#31 0x00007ff6f61daff8 _ZN16QCoreApplication4execEv (libQt5Core.so.5)
#32 0x000055d52a3823e3 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#33 0x00007ff6f54cdf4a __libc_start_main (libc.so.6)
#34 0x000055d52a38132a n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
Refusing to dump core to tty (use shell redirection or specify --output).
When compiling with asan, the same procedure (create new db, add entry) gives the following output:
ASAN:DEADLYSIGNAL
=================================================================
==18024==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f50da5c3f4a bp 0x0c18001d4c76 sp 0x7ffd894aaa20 T0)
==18024==The signal is caused by a READ memory access.
==18024==Hint: address points to the zero page.
#0 0x7f50da5c3f49 in QCoreApplication::postEvent(QObject*, QEvent*, int) (/usr/lib/libQt5Core.so.5+0x29ff49)
#1 0x55db5cce2742 in EditWidgetIcons::load(Uuid const&, Database*, IconStruct const&, QString const&) (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x2da742)
#2 0x55db5cd38e15 in EditEntryWidget::setForms(Entry const*, bool) (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x330e15)
#3 0x55db5cd3b08d in EditEntryWidget::loadEntry(Entry*, bool, bool, QString const&, Database*) (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x33308d)
#4 0x55db5ccb4017 in DatabaseWidget::createEntry() (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x2ac017)
#5 0x55db5cb3ae7b in DatabaseWidget::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x132e7b)
#6 0x7f50da5f0ee5 in QMetaObject::activate(QObject*, int, int, void**) (/usr/lib/libQt5Core.so.5+0x2ccee5)
#7 0x7f50dbcfa382 in QAction::triggered(bool) (/usr/lib/libQt5Widgets.so.5+0x14b382)
#8 0x7f50dbcfcc05 in QAction::activate(QAction::ActionEvent) (/usr/lib/libQt5Widgets.so.5+0x14dc05)
#9 0x7f50dbdf7c0b (/usr/lib/libQt5Widgets.so.5+0x248c0b)
#10 0x7f50dbdf7e7d in QAbstractButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x248e7d)
#11 0x7f50dbedddea in QToolButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x32edea)
#12 0x7f50dbd40e37 in QWidget::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x191e37)
#13 0x7f50dbedde84 in QToolButton::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x32ee84)
#14 0x7f50dbd00e3b in QApplicationPrivate::notify_helper(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x151e3b)
#15 0x7f50dbd08d90 in QApplication::notify(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x159d90)
#16 0x7f50da5c06bf in QCoreApplication::notifyInternal2(QObject*, QEvent*) (/usr/lib/libQt5Core.so.5+0x29c6bf)
#17 0x7f50dbd07d19 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) (/usr/lib/libQt5Widgets.so.5+0x158d19)
#18 0x7f50dbd5c288 (/usr/lib/libQt5Widgets.so.5+0x1ad288)
#19 0x7f50dbd5e99f (/usr/lib/libQt5Widgets.so.5+0x1af99f)
#20 0x7f50dbd00e3b in QApplicationPrivate::notify_helper(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x151e3b)
#21 0x7f50dbd08815 in QApplication::notify(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x159815)
#22 0x7f50da5c06bf in QCoreApplication::notifyInternal2(QObject*, QEvent*) (/usr/lib/libQt5Core.so.5+0x29c6bf)
#23 0x7f50db4f7633 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) (/usr/lib/libQt5Gui.so.5+0x107633)
#24 0x7f50db4f9185 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) (/usr/lib/libQt5Gui.so.5+0x109185)
#25 0x7f50db4d0bbb in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) (/usr/lib/libQt5Gui.so.5+0xe0bbb)
#26 0x7f50cff402fc (/usr/lib/libQt5XcbQpa.so.5+0xc52fc)
#27 0x7f50da5bed0a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (/usr/lib/libQt5Core.so.5+0x29ad0a)
#28 0x7f50da5c7ff7 in QCoreApplication::exec() (/usr/lib/libQt5Core.so.5+0x2a3ff7)
#29 0x55db5ca93d02 in main (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x8bd02)
#30 0x7f50d98baf49 in __libc_start_main (/usr/lib/libc.so.6+0x20f49)
#31 0x55db5ca98969 in _start (/home/redacted/.sources/keepassxc/build/src/keepassxc+0x90969)
AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV (/usr/lib/libQt5Core.so.5+0x29ff49) in QCoreApplication::postEvent(QObject*, QEvent*, int)
==18024==ABORTING
Additionally, make test fails also on 28:
27/28 Test #27: testgui ..........................***Failed 7.44 sec
Start 28: testguipixmaps
28/28 Test #28: testguipixmaps ...................***Failed 0.29 sec
Could you please recompile a version in Debug mode and repost the stack trace?
Can you also run testgui directly with ./tests/gui/testgui ?
Debug enabled with ASAN, I get the following message:
ASAN:DEADLYSIGNAL
=================================================================
==32477==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f6f97a91f4a bp 0x7ffe77727ee0 sp 0x7ffe77727e50 T0)
==32477==The signal is caused by a READ memory access.
==32477==Hint: address points to the zero page.
#0 0x7f6f97a91f49 in QCoreApplication::postEvent(QObject*, QEvent*, int) (/usr/lib/libQt5Core.so.5+0x29ff49)
#1 0x557d1ec916e5 in EditWidgetIcons::resetFaviconDownload(bool) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:259
#2 0x557d1ec8f2d2 in EditWidgetIcons::setUrl(QString const&) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:154
#3 0x557d1ec8e984 in EditWidgetIcons::load(Uuid const&, Database*, IconStruct const&, QString const&) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:125
#4 0x557d1ecdfed9 in EditEntryWidget::setForms(Entry const*, bool) /home/redacted/.sources/keepassxc/src/gui/entry/EditEntryWidget.cpp:623
#5 0x557d1ecdd3d1 in EditEntryWidget::loadEntry(Entry*, bool, bool, QString const&, Database*) /home/redacted/.sources/keepassxc/src/gui/entry/EditEntryWidget.cpp:549
#6 0x557d1ec648ac in DatabaseWidget::switchToEntryEdit(Entry*, bool) /home/redacted/.sources/keepassxc/src/gui/DatabaseWidget.cpp:797
#7 0x557d1ec5eb71 in DatabaseWidget::createEntry() /home/redacted/.sources/keepassxc/src/gui/DatabaseWidget.cpp:351
#8 0x557d1eb55462 in DatabaseWidget::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) /home/redacted/.sources/keepassxc/build/src/keepassx_core_autogen/DMHXEJ42XS/moc_DatabaseWidget.cpp:408
#9 0x7f6f97abeee5 in QMetaObject::activate(QObject*, int, int, void**) (/usr/lib/libQt5Core.so.5+0x2ccee5)
#10 0x7f6f991c8382 in QAction::triggered(bool) (/usr/lib/libQt5Widgets.so.5+0x14b382)
#11 0x7f6f991cac05 in QAction::activate(QAction::ActionEvent) (/usr/lib/libQt5Widgets.so.5+0x14dc05)
#12 0x7f6f992c5c0b (/usr/lib/libQt5Widgets.so.5+0x248c0b)
#13 0x7f6f992c5e7d in QAbstractButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x248e7d)
#14 0x7f6f993abdea in QToolButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x32edea)
#15 0x7f6f9920ee37 in QWidget::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x191e37)
#16 0x7f6f993abe84 in QToolButton::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x32ee84)
#17 0x7f6f991cee3b in QApplicationPrivate::notify_helper(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x151e3b)
#18 0x7f6f991d6d90 in QApplication::notify(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x159d90)
#19 0x7f6f97a8e6bf in QCoreApplication::notifyInternal2(QObject*, QEvent*) (/usr/lib/libQt5Core.so.5+0x29c6bf)
#20 0x7f6f991d5d19 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) (/usr/lib/libQt5Widgets.so.5+0x158d19)
#21 0x7f6f9922a288 (/usr/lib/libQt5Widgets.so.5+0x1ad288)
#22 0x7f6f9922c99f (/usr/lib/libQt5Widgets.so.5+0x1af99f)
#23 0x7f6f991cee3b in QApplicationPrivate::notify_helper(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x151e3b)
#24 0x7f6f991d6815 in QApplication::notify(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x159815)
#25 0x7f6f97a8e6bf in QCoreApplication::notifyInternal2(QObject*, QEvent*) (/usr/lib/libQt5Core.so.5+0x29c6bf)
#26 0x7f6f989c5633 in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) (/usr/lib/libQt5Gui.so.5+0x107633)
#27 0x7f6f989c7185 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) (/usr/lib/libQt5Gui.so.5+0x109185)
#28 0x7f6f9899ebbb in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) (/usr/lib/libQt5Gui.so.5+0xe0bbb)
#29 0x7f6f8d3402fc (/usr/lib/libQt5XcbQpa.so.5+0xc52fc)
#30 0x7f6f97a8cd0a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (/usr/lib/libQt5Core.so.5+0x29ad0a)
#31 0x7f6f97a95ff7 in QCoreApplication::exec() (/usr/lib/libQt5Core.so.5+0x2a3ff7)
#32 0x557d1eab49b2 in main /home/redacted/.sources/keepassxc/src/main.cpp:155
#33 0x7f6f96d88f49 in __libc_start_main (/usr/lib/libc.so.6+0x20f49)
#34 0x557d1eab2349 in _start (/home/redacted/.sources/keepassxc/build/src/keepassxc+0xc5349)
AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV (/usr/lib/libQt5Core.so.5+0x29ff49) in QCoreApplication::postEvent(QObject*, QEvent*, int)
==32477==ABORTING
With ASAN enabled I don't get a stacktrace, so I disabled it: (although I don't see a difference between Release or Debug)
PID: 6675 (keepassxc)
UID: 1000 (redacted)
GID: 1000 (redacted)
Signal: 11 (SEGV)
Timestamp: Sat 2018-01-20 14:26:38 CET (8s ago)
Command Line: src/keepassxc
Executable: /home/redacted/.sources/keepassxc/build/src/keepassxc
Control Group: /user.slice/user-1000.slice/session-c2.scope
Unit: session-c2.scope
Slice: user-1000.slice
Session: c2
Owner UID: 1000 (redacted)
Boot ID: 51b672be8e574b19a1e3fbde8a0c5536
Machine ID: 5a3d1d090af943a8a204286c2369b26e
Hostname: redacted
Storage: /var/lib/systemd/coredump/core.keepassxc.1000.51b672be8e574b19a1e3fbde8a0c5536.6675.1516454798000000.lz4
Message: Process 6675 (keepassxc) of user 1000 dumped core.
Stack trace of thread 6675:
#0 0x00007f15d05bcf4a _ZN16QCoreApplication9postEventEP7QObjectP6QEventi (libQt5Core.so.5)
#1 0x000055ac003f53b6 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#2 0x000055ac003f4846 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#3 0x000055ac003f452a n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#4 0x000055ac00410b5d n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#5 0x000055ac0040fdff n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#6 0x000055ac003e5943 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#7 0x000055ac003e376e n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#8 0x000055ac0037c99f n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#9 0x00007f15d05e9ee6 _ZN11QMetaObject8activateEP7QObjectiiPPv (libQt5Core.so.5)
#10 0x00007f15d1cf3383 _ZN7QAction9triggeredEb (libQt5Widgets.so.5)
#11 0x00007f15d1cf5c06 _ZN7QAction8activateENS_11ActionEventE (libQt5Widgets.so.5)
#12 0x00007f15d1df0c0c n/a (libQt5Widgets.so.5)
#13 0x00007f15d1df0e7e _ZN15QAbstractButton17mouseReleaseEventEP11QMouseEvent (libQt5Widgets.so.5)
#14 0x00007f15d1ed6deb _ZN11QToolButton17mouseReleaseEventEP11QMouseEvent (libQt5Widgets.so.5)
#15 0x00007f15d1d39e38 _ZN7QWidget5eventEP6QEvent (libQt5Widgets.so.5)
#16 0x00007f15d1ed6e85 _ZN11QToolButton5eventEP6QEvent (libQt5Widgets.so.5)
#17 0x00007f15d1cf9e3c _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5)
#18 0x00007f15d1d01d91 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5)
#19 0x00007f15d05b96c0 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5)
#20 0x00007f15d1d00d1a _ZN19QApplicationPrivate14sendMouseEventEP7QWidgetP11QMouseEventS1_S1_PS1_R8QPointerIS0_Eb (libQt5Widgets.so.5)
#21 0x00007f15d1d55289 n/a (libQt5Widgets.so.5)
#22 0x00007f15d1d579a0 n/a (libQt5Widgets.so.5)
#23 0x00007f15d1cf9e3c _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widgets.so.5)
#24 0x00007f15d1d01816 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5)
#25 0x00007f15d05b96c0 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5)
#26 0x00007f15d14f0634 _ZN22QGuiApplicationPrivate17processMouseEventEPN29QWindowSystemInterfacePrivate10MouseEventE (libQt5Gui.so.5)
#27 0x00007f15d14f2186 _ZN22QGuiApplicationPrivate24processWindowSystemEventEPN29QWindowSystemInterfacePrivate17WindowSystemEventE (libQt5Gui.so.5)
#28 0x00007f15d14c9bbc _ZN22QWindowSystemInterface22sendWindowSystemEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Gui.so.5)
#29 0x00007f15c89a52fd n/a (libQt5XcbQpa.so.5)
#30 0x00007f15d05b7d0b _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5)
#31 0x00007f15d05c0ff8 _ZN16QCoreApplication4execEv (libQt5Core.so.5)
#32 0x000055ac003415a3 n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
#33 0x00007f15cf8b3f4a __libc_start_main (libc.so.6)
#34 0x000055ac003404ea n/a (/home/redacted/.sources/keepassxc/build/src/keepassxc)
I can't run ./tests/gui/testgui with ASAN disabled:
Config: Using QtTest library 5.10.0, Qt 5.10.0 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 7.2.1 20171224)
==9032==ASan runtime does not come first in initial library list; you should either link runtime to your application or manually preload it with LD_PRELOAD.
So, I enabled it again and run the test directly:
********* Start testing of TestGui *********
Config: Using QtTest library 5.10.0, Qt 5.10.0 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 7.2.1 20171224)
QDEBUG : TestGui::initTestCase() qt5ct: D-Bus global menu: no
PASS : TestGui::initTestCase()
PASS : TestGui::testCreateDatabase()
QDEBUG : TestGui::testMergeDatabase() Updating entry Sample Entry.
QDEBUG : TestGui::testMergeDatabase() New entry pc detected. Creating it.
QDEBUG : TestGui::testMergeDatabase() New group TestExtraGroup detected. Creating it.
QDEBUG : TestGui::testMergeDatabase() New entry b detected. Creating it.
PASS : TestGui::testMergeDatabase()
ASAN:DEADLYSIGNAL
=================================================================
==17223==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f4b0999af4a bp 0x7ffff336b0a0 sp 0x7ffff336b010 T0)
==17223==The signal is caused by a READ memory access.
==17223==Hint: address points to the zero page.
#0 0x7f4b0999af49 in QCoreApplication::postEvent(QObject*, QEvent*, int) (/usr/lib/libQt5Core.so.5+0x29ff49)
#1 0x562a7cd67bf3 in EditWidgetIcons::resetFaviconDownload(bool) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:259
#2 0x562a7cd657e0 in EditWidgetIcons::setUrl(QString const&) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:154
#3 0x562a7cd64e92 in EditWidgetIcons::load(Uuid const&, Database*, IconStruct const&, QString const&) /home/redacted/.sources/keepassxc/src/gui/EditWidgetIcons.cpp:125
#4 0x562a7cc2e607 in EditEntryWidget::setForms(Entry const*, bool) /home/redacted/.sources/keepassxc/src/gui/entry/EditEntryWidget.cpp:623
#5 0x562a7cc2baff in EditEntryWidget::loadEntry(Entry*, bool, bool, QString const&, Database*) /home/redacted/.sources/keepassxc/src/gui/entry/EditEntryWidget.cpp:549
#6 0x562a7cb770b0 in DatabaseWidget::switchToEntryEdit(Entry*, bool) /home/redacted/.sources/keepassxc/src/gui/DatabaseWidget.cpp:797
#7 0x562a7cb78714 in DatabaseWidget::switchToEntryEdit() /home/redacted/.sources/keepassxc/src/gui/DatabaseWidget.cpp:929
#8 0x562a7cca17fe in DatabaseWidget::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) /home/redacted/.sources/keepassxc/build/src/keepassx_core_autogen/DMHXEJ42XS/moc_DatabaseWidget.cpp:428
#9 0x7f4b099c7ee5 in QMetaObject::activate(QObject*, int, int, void**) (/usr/lib/libQt5Core.so.5+0x2ccee5)
#10 0x7f4b0ab9e382 in QAction::triggered(bool) (/usr/lib/libQt5Widgets.so.5+0x14b382)
#11 0x7f4b0aba0c05 in QAction::activate(QAction::ActionEvent) (/usr/lib/libQt5Widgets.so.5+0x14dc05)
#12 0x7f4b0ac9bc0b (/usr/lib/libQt5Widgets.so.5+0x248c0b)
#13 0x7f4b0ac9be7d in QAbstractButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x248e7d)
#14 0x7f4b0ad81dea in QToolButton::mouseReleaseEvent(QMouseEvent*) (/usr/lib/libQt5Widgets.so.5+0x32edea)
#15 0x7f4b0abe4e37 in QWidget::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x191e37)
#16 0x7f4b0ad81e84 in QToolButton::event(QEvent*) (/usr/lib/libQt5Widgets.so.5+0x32ee84)
#17 0x7f4b0aba4e3b in QApplicationPrivate::notify_helper(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x151e3b)
#18 0x7f4b0abacd90 in QApplication::notify(QObject*, QEvent*) (/usr/lib/libQt5Widgets.so.5+0x159d90)
#19 0x562a7ca7f2ae in mouseEvent /usr/include/qt/QtTest/qtestmouse.h:229
#20 0x562a7ca7e68e in mouseEvent /usr/include/qt/QtTest/qtestmouse.h:193
#21 0x562a7cac3c70 in QTest::mouseClick(QWidget*, Qt::MouseButton, QFlags<Qt::KeyboardModifier>, QPoint, int) (/home/redacted/.sources/keepassxc/build/tests/gui/testgui+0x118c70)
#22 0x562a7ca87c34 in TestGui::testEditEntry() /home/redacted/.sources/keepassxc/tests/gui/TestGui.cpp:293
#23 0x562a7ca860a7 in TestGui::testAutoreloadDatabase() /home/redacted/.sources/keepassxc/tests/gui/TestGui.cpp:253
#24 0x562a7cacd8d7 in TestGui::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) /home/redacted/.sources/keepassxc/build/tests/gui/testgui_autogen/EWIEGA46WW/moc_TestGui.cpp:160
#25 0x7f4b099a90a2 in QMetaMethod::invoke(QObject*, Qt::ConnectionType, QGenericReturnArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument) const (/usr/lib/libQt5Core.so.5+0x2ae0a2)
#26 0x7f4b0bdcf1fd (/usr/lib/libQt5Test.so.5+0x131fd)
#27 0x7f4b0bdcff94 (/usr/lib/libQt5Test.so.5+0x13f94)
#28 0x7f4b0bdd0520 (/usr/lib/libQt5Test.so.5+0x14520)
#29 0x7f4b0bdd09db in QTest::qRun() (/usr/lib/libQt5Test.so.5+0x149db)
#30 0x7f4b0bdd0cfc in QTest::qExec(QObject*, int, char**) (/usr/lib/libQt5Test.so.5+0x14cfc)
#31 0x562a7cabe7b5 in main /home/redacted/.sources/keepassxc/tests/gui/TestGui.cpp:1090
#32 0x7f4b08c91f49 in __libc_start_main (/usr/lib/libc.so.6+0x20f49)
#33 0x562a7ca79109 in _start (/home/redacted/.sources/keepassxc/build/tests/gui/testgui+0xce109)
AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV (/usr/lib/libQt5Core.so.5+0x29ff49) in QCoreApplication::postEvent(QObject*, QEvent*, int)
==17223==ABORTING
Okay, that's a nullptr dereference caused by HTTP being off while NETWORKING is on. I can reproduce it. Thanks.
I pushed a fix.
Most helpful comment
I pushed a fix.