Bug 453875 - kdeconnect crashes on startup
Summary: kdeconnect crashes on startup
Status: REPORTED
Alias: None
Product: kdeconnect
Classification: Applications
Component: common (show other bugs)
Version: 22.04.1
Platform: Kubuntu Linux
: NOR crash
Target Milestone: ---
Assignee: Albert Vaca Cintora
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-05-16 08:45 UTC by Benjamin
Modified: 2023-01-22 02:16 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
New crash information added by DrKonqi (2.30 KB, text/plain)
2022-12-01 18:41 UTC, Ken Roberts
Details
New crash information added by DrKonqi (2.26 KB, text/plain)
2023-01-22 02:16 UTC, Suede
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin 2022-05-16 08:45:33 UTC
Hi there!
On 22.04 kdeconnect crashes. The Flatpak works but without a systray icon and no possibility to write sms and stuff...

Here is the crash report:
>Application: KDE Connect-Dienst (kdeconnectd), signal: Segmentation fault

[KCrash Handler]
#4  0x00007f0dcdb59e96 in KdeConnectConfig::deviceId() () from /lib/x86_64-linux-gnu/libkdeconnectcore.so.22
#5  0x00007f0dcdb5ebc7 in NetworkPacket::createIdentityPacket(NetworkPacket*) () from /lib/x86_64-linux-gnu/libkdeconnectcore.so.22
#6  0x00007f0dcdb4aac9 in LanLinkProvider::broadcastToNetwork() () from /lib/x86_64-linux-gnu/libkdeconnectcore.so.22
#7  0x00007f0dcc618783 in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#8  0x00007f0dcc61c7ee in QTimer::timeout(QTimer::QPrivateSignal) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#9  0x00007f0dcc60e32f in QObject::event(QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#10 0x00007f0dcd164713 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Widgets.so.5
#11 0x00007f0dcc5e0e2a in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#12 0x00007f0dcc6393db in QTimerInfoList::activateTimers() () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#13 0x00007f0dcc639cdc in ?? () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#14 0x00007f0dcab38d1b in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#15 0x00007f0dcab8d6f8 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#16 0x00007f0dcab363c3 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#17 0x00007f0dcc63a0a8 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#18 0x00007f0dcc5df74b in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#19 0x00007f0dcc5e7ce4 in QCoreApplication::exec() () from /lib/x86_64-linux-gnu/libQt5Core.so.5
#20 0x000055d9075b4fad in ?? ()
#21 0x00007f0dcbefad90 in __libc_start_call_main (main=main@entry=0x55d9075b4b70, argc=argc@entry=1, argv=argv@entry=0x7ffe8c887738) at ../sysdeps/nptl/libc_start_call_main.h:58
#22 0x00007f0dcbefae40 in __libc_start_main_impl (main=0x55d9075b4b70, argc=1, argv=0x7ffe8c887738, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffe8c887728) at ../csu/libc-start.c:392
#23 0x000055d9075b5235 in _start ()
[Inferior 1 (process 17443) detached]<
Comment 1 Andrey Rakhmatullin 2022-06-18 16:04:55 UTC
I have the same problem on Debian Testing (kdeconnect 21.12.3, Qt 5.15.2). The affected line is "d->m_certificate.subjectInfo(QSslCertificate::CommonName).constFirst()" and the drkonqi stack with debug symbols is 

[KCrash Handler]
#4  std::__atomic_base<int>::load (__m=std::memory_order_relaxed, this=0x0) at /usr/include/c++/11/bits/atomic_base.h:479
#5  QAtomicOps<int>::loadRelaxed<int> (_q_value=...) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qatomic_cxx11.h:239
#6  QBasicAtomicInteger<int>::loadRelaxed (this=0x0) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qbasicatomic.h:107
#7  QtPrivate::RefCount::ref (this=0x0) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qrefcount.h:55
#8  QString::QString (other=..., this=0x7fff8183ca78) at /usr/include/x86_64-linux-gnu/qt5/QtCore/qstring.h:1094
#9  KdeConnectConfig::deviceId (this=<optimized out>) at ./core/kdeconnectconfig.cpp:133

I've tried running it under gdb, so far I got to 

(gdb) p KdeConnectConfig::instance().d->m_certificate.subjectInfo(QSslCertificate::CommonName)
$3 = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {d = 0x7ffff6b0a5f0 <QListData::shared_null>}, d = 0x7ffff6b0a5f0 <QListData::shared_null>}}, <No data fields>}

(not sure if it's possible to learn something useful about this QList instance from this, as all methods return "Cannot evaluate function -- may be inlined")

But then I've read the output before the crash and there is "qt.network.ssl: QSslSocket: cannot resolve <many libssl symbols>" and "qt.network.ssl: Incompatible version of OpenSSL" so it looks like it's something related to the OpenSSL 3 migration. OTOH kdeconnect works without this problem on my other machine running Debian sid...
Comment 2 Andrey Rakhmatullin 2022-06-18 16:16:37 UTC
Using lsof I found that for some reason libssl1.0.2 is loaded into the process, in addition to (and later than) the correct libssl3. Removing it helped (though I don't know who loaded it, considering that the second machine has it installed but not loaded into kdeconnectd).
Comment 3 Ken Roberts 2022-12-01 18:41:26 UTC
Created attachment 154204 [details]
New crash information added by DrKonqi

kdeconnectd (22.04.1) using Qt 5.15.3

- What I was doing when the application crashed:
When logging in. Also happens when selecting restart app using crash assistant.
Dell Optiplex 3010 Intel Core i5.

-- Backtrace (Reduced):
#4  0x00007f1b54b26526 in KdeConnectConfig::deviceId() () from /lib64/libkdeconnectcore.so.22
#5  0x00007f1b54b2b247 in NetworkPacket::createIdentityPacket(NetworkPacket*) () from /lib64/libkdeconnectcore.so.22
#6  0x00007f1b54b17280 in LanLinkProvider::broadcastToNetwork() () from /lib64/libkdeconnectcore.so.22
#7  0x00007f1b53630e99 in void doActivate<false>(QObject*, int, void**) () from /lib64/libQt5Core.so.5
#8  0x00007f1b5363413e in QTimer::timeout(QTimer::QPrivateSignal) () from /lib64/libQt5Core.so.5
Comment 4 Suede 2023-01-22 02:16:25 UTC
Created attachment 155493 [details]
New crash information added by DrKonqi

kdeconnectd (22.04.1) using Qt 5.15.3

- What I was doing when the application crashed:

Logged into KDE on Rocky 9 KDE distro. KDE connect daemon immediately crashes.

-- Backtrace (Reduced):
#4  0x00007f553ad2e526 in KdeConnectConfig::deviceId() () from /lib64/libkdeconnectcore.so.22
#5  0x00007f553ad33247 in NetworkPacket::createIdentityPacket(NetworkPacket*) () from /lib64/libkdeconnectcore.so.22
#6  0x00007f553ad1f280 in LanLinkProvider::broadcastToNetwork() () from /lib64/libkdeconnectcore.so.22
#7  0x00007f5539838e99 in void doActivate<false>(QObject*, int, void**) () from /lib64/libQt5Core.so.5
#8  0x00007f553983c13e in QTimer::timeout(QTimer::QPrivateSignal) () from /lib64/libQt5Core.so.5