keepassxreboot / keepassxc

KeePassXC is a cross-platform community-driven port of the Windows application “Keepass Password Safe”.
https://keepassxc.org/
Other
21.39k stars 1.48k forks source link

KeePassXC crashing on database open if compiled with llvm's libcxx and running wayland #11385

Closed MarkusTieger closed 1 month ago

MarkusTieger commented 1 month ago

Overview

Steps to Reproduce

  1. Compile keepassxc and all the libraries that keepassxc depends on with libcxx (from llvm, instead of libstdcxx from gcc. You cannot mix libraries that are compiled with different c++ standard libraries).
  2. Open KeePassXC (ensure you are running a wayland session)
  3. Try to open a database (enter a password)

Expected Behavior

The database should open if the credentials are correct

Actual Behavior

The application crashes with a segmentation fault

Context

gdb backtrace: image

It doesn't crash inside valgrind.

It is probably something related to qt, but as it only happens with keepassxc, I opened the issue here.

KeePassXC - 2.7.9 Revision: 8f6dd13

Operating System: Gentoo Linux Desktop Env: Hyprland (also tried using Sway) Windowing System: Wayland (it doesn't crash on X11)

droidmonkey commented 1 month ago

As that stack trace does not start or end with keepassxc code, this is definitely external to our program. Technically the start of the stack trace from a "initiating" point of view is line number 19. Closing unless you can point to specific KeePassXC code cause.

MarkusTieger commented 1 month ago

As that stack trace does not start or end with keepassxc code, this is definitely external to our program. Technically the start of the stack trace from a "initiating" point of view is line number 19. Closing unless you can point to specific KeePassXC code cause.

I think I found the issue: https://bugreports.qt.io/browse/QTBUG-78652

It has been caused in qt, because of a animated cursor. Meaning the database unlock caused the "busy" cursor, which was animated and then crashed the application.

This is fixed in Qt6, but not Qt5. ~~Meaning, this issue will persist for me until KeePassXC updates to Qt6. A workarround would be to not hover over the application while unlocking.~~ Found a working patch online.

droidmonkey commented 1 month ago

We will be on qt6 for 2.8.0