Bug 467622 - screensharing crashes portal in WaylandIntegration::WaylandIntegrationPrivate::startStreamingOutput()
Summary: screensharing crashes portal in WaylandIntegration::WaylandIntegrationPrivate...
Status: RESOLVED FIXED
Alias: None
Product: xdg-desktop-portal-kde
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 5.27.3
Platform: Fedora RPMs Linux
: NOR crash
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2023-03-20 18:51 UTC by Mikko Kortelainen
Modified: 2025-10-09 10:29 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
obs-1 (63.94 KB, image/png)
2023-03-21 05:35 UTC, Mikko Kortelainen
Details
obs-2 (86.68 KB, image/png)
2023-03-21 05:35 UTC, Mikko Kortelainen
Details
obs-3 (35.67 KB, image/png)
2023-03-21 05:35 UTC, Mikko Kortelainen
Details
obs-4 (108.24 KB, image/png)
2023-03-21 05:35 UTC, Mikko Kortelainen
Details
obs-5 (34.99 KB, image/png)
2023-03-21 05:35 UTC, Mikko Kortelainen
Details
obs-6 (123.85 KB, image/png)
2023-03-21 05:36 UTC, Mikko Kortelainen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mikko Kortelainen 2023-03-20 18:51:49 UTC
Application: xdg-desktop-portal-kde (5.27.3)

Qt Version: 5.15.8
Frameworks Version: 5.104.0
Operating System: Linux 6.2.7-300.fc38.x86_64 x86_64
Windowing System: Wayland
Distribution: Fedora Linux 38 (Thirty Eight Prerelease)
DrKonqi: 5.27.3 [KCrashBackend]

-- Information about the crash:
Choosing "new virtual output" on portal screensharing, stopping shareing and sharing again shows incorrect number of output monitors, selecting one without a name crashes

obs logs:

info: [pipewire] Stream 0x556a2ebc47c0 state: "unconnected" (error: none)
info: PipeWire initialized
info: [pipewire] Screencast session created
info: [pipewire] Asking for desktop
warning: [pipewire] Failed to start screencast, denied or cancelled by user


xdg-desktop-portal-kde logs:

QT_LOGGING_RULES='*.debug=true' /usr/libexec/xdg-desktop-portal-kde -rv

kf.wayland.client: Unknown interface announced:  kde_output_device_v2 / 63 / 2
kf.wayland.client: Wayland Interface:  wl_output / 64 / 4
qt.qpa.wayland: Received xdg_toplevel.configure with QSize(1870, 1051) and QFlags<Qt::WindowState>(WindowMaximized)
qt.qpa.wayland: Applied pending xdg_toplevel configure event: QSize(1870, 1051) QFlags<Qt::WindowState>(WindowMaximized)
qt.scenegraph.renderloop: exposureChanged() ApplicationWindow_QMLTYPE_49_QML_78(0x55596cdd9ab0 exposed, visibility=QWindow::Maximized, flags=QFlags<Qt::WindowType>(Window), title="Portal", geometry=0,0 1870x1051)
qt.scenegraph.renderloop: handleExposure() ApplicationWindow_QMLTYPE_49_QML_78(0x55596cdd9ab0 exposed, visibility=QWindow::Maximized, flags=QFlags<Qt::WindowType>(Window), title="Portal", geometry=0,0 1870x1051)
qt.scenegraph.renderloop: - render thread already running
qt.scenegraph.renderloop: polishAndSync (in expose) ApplicationWindow_QMLTYPE_49_QML_78(0x55596cdd9ab0 exposed, visibility=QWindow::Maximized, flags=QFlags<Qt::WindowType>(Window), title="Portal", geometry=0,0 1870x1051)
qt.scenegraph.renderloop: - lock for sync
qt.scenegraph.renderloop: - wait for sync
qt.scenegraph.renderloop:                     (RT) WM_RequestSync
qt.scenegraph.renderloop:                     (RT) - triggered from expose
qt.scenegraph.renderloop:                     (RT) --- done processEventsAndWaitForMore()
qt.scenegraph.renderloop:                     (RT) syncAndRender()
qt.scenegraph.renderloop:                     (RT) - updatePending, doing sync
qt.scenegraph.renderloop:                     (RT) sync()
qt.quick.dirty: QQuickWindowPrivate::updateDirtyNodes():
qt.scenegraph.renderloop:                     (RT) - rendering started
qt.scenegraph.time.renderer: time in renderer: total=0ms, preprocess=0, updates=0, binding=0, rendering=0
qt.qpa.wayland.backingstore: handleUpdate QSGRenderThread(0x55596d1fa180)
qt.scenegraph.renderloop:                     (RT) - rendering done
qt.scenegraph.renderloop:                     (RT) - wake Gui after expose
qt.scenegraph.renderloop: - unlock after sync
qt.scenegraph.time.renderloop: Frame prepared with 'threaded' renderloop, polish=0, lock=0, blockedForSync=8, animations=0 - (on Gui thread) ApplicationWindow_QMLTYPE_49_QML_78(0x55596cdd9ab0 exposed, visibility=QWindow::Maximized, flags=QFlags<Qt::WindowType>(Window), title="Portal", geometry=0,0 1870x1051)
qt.scenegraph.renderloop: - done with handleExposure()
qt.scenegraph.time.renderloop: Frame rendered with 'threaded' renderloop in 8ms, sync=0, render=0, swap=8 - (on render thread)
qt.scenegraph.renderloop:                     (RT) --- begin processEvents()
qt.scenegraph.renderloop:                     (RT) --- done processEvents()
qt.scenegraph.renderloop:                     (RT) done drawing, sleep...
qt.scenegraph.renderloop:                     (RT) --- begin processEventsAndWaitForMore()



xdg-desktop-portal
(/usr/libexec/xdg-desktop-portal:8780): xdg-desktop-portal-WARNING **: 20:48:36.142: A backend call failed: Remote peer disconnected
XDP: screen cast session owned by ':1.352' closed

i have not been able to do a screenshare not even once on wayland. x11 works just fine. the hover on taskbar tasks do not show the content either. i think they are using the same mechanism to get the image for the application state.

on xdg-desktop-portal launch:

(/usr/libexec/xdg-desktop-portal:8780): xdg-desktop-portal-WARNING **: 20:28:51.368: Failed to create background monitor: Failed to own background monitor D-Bus name

(/usr/libexec/xdg-desktop-portal:8780): xdg-desktop-portal-WARNING **: 20:28:51.368: No skeleton to export

The crash can be reproduced every time.

-- Backtrace:
Application: Portal (xdg-desktop-portal-kde), signal: Segmentation fault

[KCrash Handler]
#4  0x00007faef24baa74 in KWayland::Client::Output::globalPosition() const () from /lib64/libKF5WaylandClient.so.5
#5  0x000056394ed6c77c in WaylandIntegration::WaylandIntegrationPrivate::startStreamingOutput(unsigned int, Screencasting::CursorMode) ()
#6  0x000056394ed5ba99 in ScreenCastPortal::Start(QDBusObjectPath const&, QDBusObjectPath const&, QString const&, QString const&, QMap<QString, QVariant> const&, QMap<QString, QVariant>&) ()
#7  0x000056394ed34c30 in ScreenCastPortal::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) ()
#8  0x000056394ed395f2 in ScreenCastPortal::qt_metacall(QMetaObject::Call, int, void**) ()
#9  0x00007faef10d944b in QDBusConnectionPrivate::deliverCall(QObject*, int, QDBusMessage const&, QVector<int> const&, int) () from /lib64/libQt5DBus.so.5
#10 0x00007faef10dd42d in QDBusConnectionPrivate::activateCall(QObject*, int, QDBusMessage const&) [clone .part.0] () from /lib64/libQt5DBus.so.5
#11 0x00007faef10ddc39 in QDBusConnectionPrivate::activateObject(QDBusConnectionPrivate::ObjectTreeNode&, QDBusMessage const&, int) () from /lib64/libQt5DBus.so.5
#12 0x00007faef10dff24 in QDBusActivateObjectEvent::placeMetaCall(QObject*) () from /lib64/libQt5DBus.so.5
#13 0x00007faef00def9b in QObject::event(QEvent*) () from /lib64/libQt5Core.so.5
#14 0x00007faef19aeca5 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /lib64/libQt5Widgets.so.5
#15 0x00007faef00b35a8 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () from /lib64/libQt5Core.so.5
#16 0x00007faef00b6a55 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /lib64/libQt5Core.so.5
#17 0x00007faef010669f in postEventSourceDispatch(_GSource*, int (*)(void*), void*) () from /lib64/libQt5Core.so.5
#18 0x00007faeee513788 in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#19 0x00007faeee571dd8 in g_main_context_iterate.isra () from /lib64/libglib-2.0.so.0
#20 0x00007faeee511113 in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#21 0x00007faef0106189 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib64/libQt5Core.so.5
#22 0x00007faef00b1f7b in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /lib64/libQt5Core.so.5
#23 0x00007faef00ba1fb in QCoreApplication::exec() () from /lib64/libQt5Core.so.5
#24 0x000056394ed3015a in main ()
[Inferior 1 (process 8751) detached]

The reporter indicates this bug may be a duplicate of or related to bug 448781.

Reported using DrKonqi
Comment 1 Aleix Pol 2023-03-20 19:44:51 UTC
This is a bit confusing, you are talking about sharing the "new virtual output" but the stack trace is on the section to stream an output and presumably one that does not exist.

How reproducible is this? Is there a chance you can provide the backtrace with debug symbols?

For what it's worth, sharing a new virtual output works fine on my system.
Comment 2 Mikko Kortelainen 2023-03-21 05:35:14 UTC
Created attachment 157478 [details]
obs-1
Comment 3 Mikko Kortelainen 2023-03-21 05:35:26 UTC
Created attachment 157479 [details]
obs-2
Comment 4 Mikko Kortelainen 2023-03-21 05:35:36 UTC
Created attachment 157480 [details]
obs-3
Comment 5 Mikko Kortelainen 2023-03-21 05:35:46 UTC
Created attachment 157481 [details]
obs-4
Comment 6 Mikko Kortelainen 2023-03-21 05:35:59 UTC
Created attachment 157482 [details]
obs-5
Comment 7 Mikko Kortelainen 2023-03-21 05:36:12 UTC
Created attachment 157483 [details]
obs-6
Comment 8 Mikko Kortelainen 2023-03-21 05:38:43 UTC
Thread 1 "xdg-desktop-por" received signal SIGSEGV, Segmentation fault.
KWayland::Client::Output::globalPosition (this=this@entry=0x0) at /usr/include/qt5/QtCore/qscopedpointer.h:116
116         T *operator->() const noexcept


(gdb) where
#0  KWayland::Client::Output::globalPosition (this=this@entry=0x0) at /usr/include/qt5/QtCore/qscopedpointer.h:116
#1  0x000055760e78f77c in WaylandIntegration::WaylandIntegrationPrivate::startStreamingOutput (this=0x55760e7e2500 <_ZZN12_GLOBAL__N_130Q_QGS_globalWaylandIntegration13innerFunctionEvE6holder.lto_priv.0>, 
    outputName=<optimized out>, mode=Screencasting::Metadata) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/waylandintegration.cpp:285
#2  0x000055760e77ea99 in WaylandIntegration::startStreamingOutput (mode=Screencasting::Metadata, outputName=60) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/waylandintegration.cpp:115
#3  ScreenCastPortal::Start (this=<optimized out>, handle=..., session_handle=..., app_id=..., parent_window=..., options=..., results=...)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/screencast.cpp:268
#4  0x000055760e757c30 in ScreenCastPortal::qt_static_metacall (_o=_o@entry=0x557610020b20, _c=_c@entry=QMetaObject::InvokeMetaMethod, _id=_id@entry=2, _a=_a@entry=0x7fff4f064dd0)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/redhat-linux-build/src/xdg-desktop-portal-kde_autogen/EWIEGA46WW/moc_screencast.cpp:143
#5  0x000055760e75c5f2 in ScreenCastPortal::qt_metacall (this=0x557610020b20, _c=QMetaObject::InvokeMetaMethod, _id=2, _a=0x7fff4f064dd0)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/redhat-linux-build/src/xdg-desktop-portal-kde_autogen/EWIEGA46WW/moc_screencast.cpp:223
#6  0x00007fce1df9244b in QDBusConnectionPrivate::deliverCall (this=this@entry=0x7fce04001680, object=object@entry=0x557610020b20, msg=..., metaTypes=..., slotIdx=<optimized out>)
    at qdbusintegrator.cpp:1001
#7  0x00007fce1df9642d in QDBusConnectionPrivate::activateCall (this=this@entry=0x7fce04001680, object=0x557610020b20, flags=flags@entry=273, msg=...) at qdbusintegrator.cpp:911
#8  0x00007fce1df96c39 in QDBusConnectionPrivate::activateCall (msg=..., flags=273, object=<optimized out>, this=0x7fce04001680) at qdbusintegrator.cpp:853
#9  QDBusConnectionPrivate::activateObject (this=0x7fce04001680, node=..., msg=..., pathStartPos=<optimized out>) at qdbusintegrator.cpp:1503
#10 0x00007fce1df98f24 in QDBusActivateObjectEvent::placeMetaCall (this=0x557610318b60) at qdbusintegrator.cpp:1623
#11 0x00007fce1d4def9b in QObject::event (this=0x557610005560, e=0x557610318b60) at kernel/qobject.cpp:1347
#12 0x00007fce1edaeca5 in QApplicationPrivate::notify_helper (this=<optimized out>, receiver=0x557610005560, e=0x557610318b60) at kernel/qapplication.cpp:3640
#13 0x00007fce1d4b35a8 in QCoreApplication::notifyInternal2 (receiver=0x557610005560, event=0x557610318b60) at kernel/qcoreapplication.cpp:1064
#14 0x00007fce1d4b37c2 in QCoreApplication::sendEvent (receiver=<optimized out>, event=<optimized out>) at kernel/qcoreapplication.cpp:1462
#15 0x00007fce1d4b6a55 in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0x55760fe210b0) at kernel/qcoreapplication.cpp:1821
#16 0x00007fce1d4b6d0d in QCoreApplication::sendPostedEvents (receiver=<optimized out>, event_type=<optimized out>) at kernel/qcoreapplication.cpp:1680
#17 0x00007fce1d50669f in postEventSourceDispatch (s=0x55760fe408e0) at kernel/qeventdispatcher_glib.cpp:277
#18 0x00007fce1b713788 in g_main_dispatch (context=0x7fce04000ee0) at ../glib/gmain.c:3460
#19 g_main_context_dispatch (context=0x7fce04000ee0) at ../glib/gmain.c:4200
#20 0x00007fce1b771dd8 in g_main_context_iterate.isra.0 (context=0x7fce04000ee0, block=1, dispatch=1, self=<optimized out>) at ../glib/gmain.c:4276
#21 0x00007fce1b711113 in g_main_context_iteration (context=0x7fce04000ee0, may_block=1) at ../glib/gmain.c:4343
#22 0x00007fce1d506189 in QEventDispatcherGlib::processEvents (this=0x55760fe420d0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
#23 0x00007fce1d4b1f7b in QEventLoop::exec (this=this@entry=0x7fff4f065460, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
#24 0x00007fce1d4ba1fb in QCoreApplication::exec () at ../../include/QtCore/../../src/corelib/global/qflags.h:121
#25 0x00007fce1d95f5bd in QGuiApplication::exec () at kernel/qguiapplication.cpp:1863
#26 0x00007fce1edaec19 in QApplication::exec () at kernel/qapplication.cpp:2832
#27 0x000055760e75315a in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/xdg-desktop-portal-kde.cpp:46


in detail

(gdb) bt full
#0  KWayland::Client::Output::globalPosition (this=this@entry=0x0) at /usr/include/qt5/QtCore/qscopedpointer.h:116
No locals.
#1  0x000055760e78f77c in WaylandIntegration::WaylandIntegrationPrivate::startStreamingOutput (this=0x55760e7e2500 <_ZZN12_GLOBAL__N_130Q_QGS_globalWaylandIntegration13innerFunctionEvE6holder.lto_priv.0>, 
    outputName=<optimized out>, mode=Screencasting::Metadata) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/waylandintegration.cpp:285
        output = <optimized out>
#2  0x000055760e77ea99 in WaylandIntegration::startStreamingOutput (mode=Screencasting::Metadata, outputName=60) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/waylandintegration.cpp:115
No locals.
#3  ScreenCastPortal::Start (this=<optimized out>, handle=..., session_handle=..., app_id=..., parent_window=..., options=..., results=...)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/screencast.cpp:268
        stream = {stream = 0x0, nodeId = 0, map = {d = 0x7fce1d588c80 <QMapDataBase::shared_null>}}
        output = @0x55761056d7d0: {m_outputType = WaylandIntegration::WaylandOutput::Monitor, m_waylandOutputName = 60, m_display = {d = 0x557610514060}, m_uniqueId = {d = 0x55760fe4ae00}, m_name = {
            d = 0x557610513bf0}}
        __for_range = @0x7fff4f064b58: {<QListSpecialMethods<Output>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, 
                end = 0, array = {0x0}}, d = 0x5576109e6db0}, d = 0x5576109e6db0}}
        __for_begin = <optimized out>
        __for_end = <optimized out>
        outputs = {<QListSpecialMethods<QVariant>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {0x0}}, 
              d = 0x7fce1d588c40 <QListData::shared_null>}, d = 0x7fce1d588c40 <QListData::shared_null>}}
        windows = {<QList<QString>> = {<QListSpecialMethods<QString>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, 
                  end = 0, array = {0x0}}, d = 0x7fce1d588c40 <QListData::shared_null>}, d = 0x7fce1d588c40 <QListData::shared_null>}}, <No data fields>}
        streams = {d = 0x7fce1d588160 <QArrayData::shared_null>}
        cursorMode = Screencasting::Metadata
        session = {wp = {d = 0x7fce04004b50, value = 0x55761036e340}}
        persist = <optimized out>
        valid = <optimized out>
        selectedOutputs = {<QListSpecialMethods<Output>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {
                  0x0}}, d = 0x5576109e6db0}, d = 0x5576109e6db0}}
        selectedWindows = {d = 0x7fce1d588160 <QArrayData::shared_null>}
        allowRestore = <optimized out>
#4  0x000055760e757c30 in ScreenCastPortal::qt_static_metacall (_o=_o@entry=0x557610020b20, _c=_c@entry=QMetaObject::InvokeMetaMethod, _id=_id@entry=2, _a=_a@entry=0x7fff4f064dd0)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/redhat-linux-build/src/xdg-desktop-portal-kde_autogen/EWIEGA46WW/moc_screencast.cpp:143
        _r = <optimized out>
        _t = 0x557610020b20
#5  0x000055760e75c5f2 in ScreenCastPortal::qt_metacall (this=0x557610020b20, _c=QMetaObject::InvokeMetaMethod, _id=2, _a=0x7fff4f064dd0)
    at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/redhat-linux-build/src/xdg-desktop-portal-kde_autogen/EWIEGA46WW/moc_screencast.cpp:223
No locals.
#6  0x00007fce1df9244b in QDBusConnectionPrivate::deliverCall (this=this@entry=0x7fce04001680, object=object@entry=0x557610020b20, msg=..., metaTypes=..., slotIdx=<optimized out>)
    at qdbusintegrator.cpp:1001
        context = {connection = {d = 0x7fce04001680}, message = @0x557610318bc0}
        old = 0x0
        ptr = <optimized out>
        params = {a = 10, s = 7, ptr = 0x7fff4f064dd0, {
            array = "\320Q6\020vU\000\000@\2412\020vU\000\000\320\3354\020vU\000\000\200\231-\020vU\000\000\2205\001\004\316\177\000\000\220\221/\020vU\000\000`\231-\020vU\000\000j\t0\035\316\177\000\000\220=w\035\316\177\000\000\020\000\000\000\000\000\000", q_for_alignment_1 = 93965566497232, q_for_alignment_2 = 4.6425158298293527e-310}}
        auxParameters = {<QListSpecialMethods<QVariant>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {
                  0x0}}, d = 0x5576102d6ae0}, d = 0x5576102d6ae0}}
        i = <optimized out>
        pCount = <optimized out>
        numMetaTypes = <optimized out>
        outputArgs = {<QListSpecialMethods<QVariant>> = {<No data fields>}, {p = {static shared_null = {ref = {atomic = {_q_value = std::atomic<int> = { -1 }}}, alloc = 0, begin = 0, end = 0, array = {
                  0x0}}, d = 0x557610322b50}, d = 0x557610322b50}}
        null = 0x0
        fail = <optimized out>
#7  0x00007fce1df9642d in QDBusConnectionPrivate::activateCall (this=this@entry=0x7fce04001680, object=0x557610020b20, flags=flags@entry=273, msg=...) at qdbusintegrator.cpp:911
        slotCache = {hash = {<QHash<QString, QDBusSlotCache::Data>> = {{d = 0x5576101d8440, e = 0x5576101d8440}}, <No data fields>}}
        cacheKey = {d = 0x55761037e950}
        signature = {d = 0x5576109cbb70}
        cacheIt = {i = 0x5576101df770}
        cachePropertyName = "_qdbus_slotCache"
#8  0x00007fce1df96c39 in QDBusConnectionPrivate::activateCall (msg=..., flags=273, object=<optimized out>, this=0x7fce04001680) at qdbusintegrator.cpp:853
        slotCache = <optimized out>
        cacheKey = <optimized out>
        signature = <optimized out>
        cacheIt = <optimized out>
        cachePropertyName = "_qdbus_slotCache"
        mo = <optimized out>
        memberName = <optimized out>
        slotData = <optimized out>
#9  QDBusConnectionPrivate::activateObject (this=0x7fce04001680, node=..., msg=..., pathStartPos=<optimized out>) at qdbusintegrator.cpp:1503
        it = 0x557610036f08
        newflags = <optimized out>
        connector = <optimized out>
#10 0x00007fce1df98f24 in QDBusActivateObjectEvent::placeMetaCall (this=0x557610318b60) at qdbusintegrator.cpp:1623
        that = <optimized out>
#11 0x00007fce1d4def9b in QObject::event (this=0x557610005560, e=0x557610318b60) at kernel/qobject.cpp:1347
        mce = 0x557610318b60
        sender = {previous = 0x0, receiver = 0x557610005560, sender = 0x7fce04001680, signal = -1}
#12 0x00007fce1edaeca5 in QApplicationPrivate::notify_helper (this=<optimized out>, receiver=0x557610005560, e=0x557610318b60) at kernel/qapplication.cpp:3640
        consumed = false
        filtered = false
#13 0x00007fce1d4b35a8 in QCoreApplication::notifyInternal2 (receiver=0x557610005560, event=0x557610318b60) at kernel/qcoreapplication.cpp:1064
        selfRequired = true
        result = false
        cbdata = {0x557610005560, 0x557610318b60, 0x7fff4f0650df}
        d = <optimized out>
        threadData = 0x55760fe210b0
        scopeLevelCounter = {threadData = 0x55760fe210b0}
#14 0x00007fce1d4b37c2 in QCoreApplication::sendEvent (receiver=<optimized out>, event=<optimized out>) at kernel/qcoreapplication.cpp:1462
No locals.
#15 0x00007fce1d4b6a55 in QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0x55760fe210b0) at kernel/qcoreapplication.cpp:1821
        e = 0x557610318b60
        pe = <optimized out>
        r = 0x557610005560
        relocker = <optimized out>
        event_deleter = {d = 0x557610318b60}
        locker = {_M_device = 0x55760fe210e0, _M_owns = false}
        startOffset = 0
        i = @0x55760fe210d4: 0
        cleanup = {receiver = 0x0, event_type = 0, data = 0x55760fe210b0, exceptionCaught = true}
#16 0x00007fce1d4b6d0d in QCoreApplication::sendPostedEvents (receiver=<optimized out>, event_type=<optimized out>) at kernel/qcoreapplication.cpp:1680
        data = <optimized out>
#17 0x00007fce1d50669f in postEventSourceDispatch (s=0x55760fe408e0) at kernel/qeventdispatcher_glib.cpp:277
        source = 0x55760fe408e0
#18 0x00007fce1b713788 in g_main_dispatch (context=0x7fce04000ee0) at ../glib/gmain.c:3460
        dispatch = 0x7fce1d506680 <postEventSourceDispatch(GSource*, GSourceFunc, gpointer)>
        prev_source = 0x0
        begin_time_nsec = 1155445985129
        was_in_call = 0
        user_data = 0x0
        callback = 0x0
        cb_funcs = 0x0
        cb_data = 0x0
        need_destroy = <optimized out>
        source = 0x55760fe408e0
        current = 0x55760ffd9690
        i = 0
        current = <optimized out>
        i = <optimized out>
        __func__ = <optimized out>
        source = <optimized out>
        _g_boolean_var_165 = <optimized out>
        was_in_call = <optimized out>
        user_data = <optimized out>
        callback = <optimized out>
        cb_funcs = <optimized out>
        cb_data = <optimized out>
        need_destroy = <optimized out>
        dispatch = <optimized out>
        prev_source = <optimized out>
        begin_time_nsec = <optimized out>
        _g_boolean_var_166 = <optimized out>
#19 g_main_context_dispatch (context=0x7fce04000ee0) at ../glib/gmain.c:4200
No locals.
#20 0x00007fce1b771dd8 in g_main_context_iterate.isra.0 (context=0x7fce04000ee0, block=1, dispatch=1, self=<optimized out>) at ../glib/gmain.c:4276
        max_priority = 2147483647
        timeout = 56
        some_ready = 1
        nfds = 1
        allocated_nfds = <optimized out>
        fds = <optimized out>
        begin_time_nsec = 1155444745471
#21 0x00007fce1b711113 in g_main_context_iteration (context=0x7fce04000ee0, may_block=1) at ../glib/gmain.c:4343
        retval = <optimized out>
#22 0x00007fce1d506189 in QEventDispatcherGlib::processEvents (this=0x55760fe420d0, flags=...) at kernel/qeventdispatcher_glib.cpp:423
        d = 0x55760fe3ac10
        canWait = <optimized out>
        savedFlags = {i = 0}
        result = <optimized out>
#23 0x00007fce1d4b1f7b in QEventLoop::exec (this=this@entry=0x7fff4f065460, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69
        d = 0x7fce0400b600
        threadData = <optimized out>
        locker = {val = 93965560975784}
        ref = {d = 0x7fce0400b600, locker = @0x7fff4f0653e8, exceptionCaught = true}
        app = 0x7fff4f065530
#24 0x00007fce1d4ba1fb in QCoreApplication::exec () at ../../include/QtCore/../../src/corelib/global/qflags.h:121
        threadData = 0x55760fe210b0
        eventLoop = {<QObject> = {_vptr.QObject = 0x7fce1d766b48 <vtable for QEventLoop+16>, static staticMetaObject = {d = {superdata = {direct = 0x0}, 
                stringdata = 0x7fce1d66c7a0 <qt_meta_stringdata_QObject>, data = 0x7fce1d66c680 <qt_meta_data_QObject>, 
                static_metacall = 0x7fce1d4e5250 <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x7fce0400b600}, 
            static staticQtMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7fce1d66f740 <qt_meta_stringdata_Qt>, data = 0x7fce1d66c8c0 <qt_meta_data_Qt>, static_metacall = 0x0, 
                relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7fce1d75e3c0 <QObject::staticMetaObject>}, 
              stringdata = 0x7fce1d666580 <qt_meta_stringdata_QEventLoop>, data = 0x7fce1d666520 <qt_meta_data_QEventLoop>, 
              static_metacall = 0x7fce1d4b1b80 <QEventLoop::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
        returnCode = <optimized out>
#25 0x00007fce1d95f5bd in QGuiApplication::exec () at kernel/qguiapplication.cpp:1863
No locals.
#26 0x00007fce1edaec19 in QApplication::exec () at kernel/qapplication.cpp:2832
No locals.
#27 0x000055760e75315a in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/xdg-desktop-portal-kde-5.27.3-1.fc38.x86_64/src/xdg-desktop-portal-kde.cpp:46
        a = {<QGuiApplication> = {<QCoreApplication> = {<QObject> = {_vptr.QObject = 0x7fce1f2ce428 <vtable for QApplication+16>, static staticMetaObject = {d = {superdata = {direct = 0x0}, 
                    stringdata = 0x7fce1d66c7a0 <qt_meta_stringdata_QObject>, data = 0x7fce1d66c680 <qt_meta_data_QObject>, 
                    static_metacall = 0x7fce1d4e5250 <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x55760fe229e0}, 
                static staticQtMetaObject = {d = {superdata = {direct = 0x0}, stringdata = 0x7fce1d66f740 <qt_meta_stringdata_Qt>, data = 0x7fce1d66c8c0 <qt_meta_data_Qt>, static_metacall = 0x0, 
                    relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = {direct = 0x7fce1d75e3c0 <QObject::staticMetaObject>}, 
                  stringdata = 0x7fce1d666c60 <qt_meta_stringdata_QCoreApplication>, data = 0x7fce1d666b40 <qt_meta_data_QCoreApplication>, 
                  static_metacall = 0x7fce1d4b4eb0 <QCoreApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, 
              static self = 0x7fff4f065530}, static staticMetaObject = {d = {superdata = {direct = 0x7fce1d766ce0 <QCoreApplication::staticMetaObject>}, 
                stringdata = 0x7fce1dd315c0 <qt_meta_stringdata_QGuiApplication>, data = 0x7fce1dd31340 <qt_meta_data_QGuiApplication>, 
                static_metacall = 0x7fce1d960670 <QGuiApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {
            d = {superdata = {direct = 0x7fce1de16b20 <QGuiApplication::staticMetaObject>}, stringdata = 0x7fce1f1868c0 <qt_meta_stringdata_QApplication>, data = 0x7fce1f186740 <qt_meta_data_QApplication>, 
              static_metacall = 0x7fce1edb29e0 <QApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
        about = {d = std::unique_ptr<KAboutDataPrivate> = {get() = 0x55760fef7460}}
        sessionBus = {d = 0x7fce04001680}
Comment 9 Mikko Kortelainen 2023-03-21 05:41:14 UTC
i can confirm btw that under wlroots screensharing works
Comment 10 Bug Janitor Service 2023-04-04 23:09:21 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/merge_requests/184
Comment 11 Aleix Pol 2023-04-04 23:23:59 UTC
I've put together the MR above. I think it can and should go in as is, it will help our debugging though if you can try compiling it and testing before 5.27.5 is released so maybe we can have the proper fix in there.

I tried setting up new virtual outputs several times, stopping and re-enabling them and it worked well (great actually ^^'). Not sure what else to test.
Comment 12 Aleix Pol 2023-04-05 16:37:01 UTC
Git commit 58313fac8188163c9445bb9a212405412258ef5e by Aleix Pol Gonzalez.
Committed on 05/04/2023 at 16:36.
Pushed by apol into branch 'Plasma/5.27'.

screencast: Don't try to screencast nullptr

For some reason we were received an output that was null. Account for it
by notifying and outputing some more information in hopes of fixing it
soon.

M  +8    -0    src/waylandintegration.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/commit/58313fac8188163c9445bb9a212405412258ef5e
Comment 13 Aleix Pol 2023-04-05 17:10:53 UTC
Git commit f4305123d418ea63942dd7b00ab6adb4abcb54eb by Aleix Pol Gonzalez.
Committed on 05/04/2023 at 17:10.
Pushed by apol into branch 'master'.

screencast: Don't try to screencast nullptr

For some reason we were received an output that was null. Account for it
by notifying and outputing some more information in hopes of fixing it
soon.


(cherry picked from commit 58313fac8188163c9445bb9a212405412258ef5e)

M  +8    -0    src/waylandintegration.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/commit/f4305123d418ea63942dd7b00ab6adb4abcb54eb
Comment 14 David Edmundson 2025-10-09 10:29:51 UTC
This crash report is quite old, there have been a lot of changes in the meantime. Can you reopen if the bug still persists with Plasma 6.4 or newer.