Skip to content

OBS Studio Crashes on Arch Linux after selecting screen (pipewire) #9733

Closed

Description

@jonhoo

Operating System Info

Other

Other OS

Arch Linux

OBS Studio Version

Git

OBS Studio Version (Other)

b29a44a

OBS Studio Log URL

OBS won't let me upload an old-enough log file. Will attach instead.

OBS Studio Crash Log URL

No response

Expected Behavior

Full screen recording on selected monitor.

Current Behavior

OBS crashes after the second time I select the screen (I'm not sure why, but OBS always asks me twice for which screen to use on start-up), with:

(lldb) bt
* thread #28, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x30)
  * frame #0: 0x00007fffc7e3e8ec linux-pipewire.so`renegotiate_format(data=0x0000555557a102e0, expirations=<unavailable>) at pipewire.c:631:2
    frame #1: 0x00007fffbffe4cc9 libspa-support.so`source_event_func(source=0x00005555574dcc60) at loop.c:663:2
    frame #2: 0x00007fffbffe6666 libspa-support.so`loop_iterate(object=0x00005555574af308, timeout=<unavailable>) at loop.c:496:4
    frame #3: 0x00007fff88cda14d libpipewire-0.3.so.0`do_loop(user_data=0x0000555557315260) at thread-loop.c:295:14
    frame #4: 0x00007ffff3eaa9eb libc.so.6`start_thread(arg=<unavailable>) at pthread_create.c:444:8
    frame #5: 0x00007ffff3f2e7cc libc.so.6`__clone3 at clone3.S:78

I'm running:

  • obs-studio @ b29a44a
  • pipewire: 0.3.82
  • hyprland: 0.30.0
  • xdg-desktop-portal-hyprland: 1.2.2

on Arch Linux. The logs just prior to the crash are:

09:01:45.260: [pipewire] Asking for desktop
09:01:46.292: [pipewire] Asking for desktop
09:01:46.293: [pipewire] desktop selected, setting up screencast
09:01:46.294: [pipewire] desktop selected, setting up screencast
09:01:46.565: [pipewire] Server version: 0.3.82
09:01:46.565: [pipewire] Library version: 0.3.82
09:01:46.565: [pipewire] Header version: 0.3.82
09:01:46.565: [pipewire] Created stream 0x5555574dccd0
09:01:46.565: [pipewire] Stream 0x5555574dccd0 state: "connecting" (error: none)
09:01:46.566: [pipewire] Playing stream 0x5555574dccd0
09:01:46.602: [pipewire] Stream 0x5555574dccd0 state: "paused" (error: none)
09:01:46.603: [pipewire] Server version: 0.3.82
09:01:46.603: [pipewire] Library version: 0.3.82
09:01:46.603: [pipewire] Header version: 0.3.82
09:01:46.603: [pipewire] Negotiated format:
09:01:46.603: [pipewire]     Format: 8 (Spa:Enum:VideoFormat:BGRx)
09:01:46.603: [pipewire]     Modifier: 0x0
09:01:46.603: [pipewire]     Size: 3840x2160
09:01:46.603: [pipewire]     Framerate: 0/1
09:01:46.603: [pipewire] Created stream 0x555557511cf0
09:01:46.603: [pipewire] Stream 0x555557511cf0 state: "connecting" (error: none)
09:01:46.603: [pipewire] Playing stream 0x555557511cf0
09:01:46.603: [pipewire] Stream 0x555557511cf0 state: "paused" (error: none)
09:01:46.603: [pipewire] Negotiated format:
09:01:46.603: [pipewire]     Format: 8 (Spa:Enum:VideoFormat:BGRx)
09:01:46.603: [pipewire]     Modifier: 0x200000028a37f04
09:01:46.603: [pipewire]     Size: 3840x2160
09:01:46.603: [pipewire]     Framerate: 0/1
09:01:46.604: [pipewire] Stream 0x5555574dccd0 state: "streaming" (error: none)
09:01:46.605: [pipewire] Negotiated format:
09:01:46.605: [pipewire]     Format: 8 (Spa:Enum:VideoFormat:BGRx)
09:01:46.605: [pipewire]     Modifier: 0x0
09:01:46.605: [pipewire]     Size: 3840x2160
09:01:46.605: [pipewire]     Framerate: 0/1
09:01:46.606: [pipewire] Negotiated format:
09:01:46.606: [pipewire]     Format: 8 (Spa:Enum:VideoFormat:BGRx)
09:01:46.606: [pipewire]     Modifier: 0x200000028a37f04
09:01:46.606: [pipewire]     Size: 3840x2160
09:01:46.606: [pipewire]     Framerate: 0/1
09:01:46.623: Cannot create EGLImage: Arguments are inconsistent (for example, a valid context requires buffers not supplied by a valid surface).
09:01:46.623: [pipewire] Renegotiating stream

If I remove all the pipewire inputs from my scene JSON config, then OBS starts just fine (and doesn't prompt me to select a screen). If I then try to add a window capture via Pipewire, it crashes again (after I select the screen).

Log file from crashing run:
2023-10-19 09-17-06.txt

Steps to Reproduce

  1. Open OBS Studio
  2. Add pipewire as a source
  3. Select a screen
  4. Crash

Anything else we should know?

Not sure if this is related to #9617.

I'm using a build of Git HEAD.

Downgrading pipewire and xdg-desktop-portal-hyprland, restarting, and then starting OBS fixes the problem.

Activity

  1. jonhoo commented on Oct 19, 2023

    @jonhoo
    Author

    Possibly related to hyprwm/xdg-desktop-portal-hyprland#112 (where the maintainer suggests it's likely an obs issue).

  2. nickc01 commented on Oct 20, 2023

    @nickc01
  3. mesmerx commented on Oct 20, 2023

    @mesmerx

    +1 same crash for me
    but my bt is a little different

    info: [pipewire] Stream 0x555558b011d0 state: "streaming" (error: none)
    error: Cannot create EGLImage: Arguments are inconsistent (for example, a valid context requires buffers not supplied by a valid surface).
    info: [pipewire] Renegotiating stream
    
    Thread 113 "PipeWire thread" received signal SIGSEGV, Segmentation fault.
    [Switching to Thread 0x7ffd52ffd6c0 (LWP 6900)]
    0x00007fff8aee799c in ?? () from /usr//lib/obs-plugins/linux-pipewire.so
    
    (gdb) bt
    #0  0x00007fff8aee799c in  () at /usr//lib/obs-plugins/linux-pipewire.so
    #1  0x00007fffb802ccb9 in  () at /usr/lib/spa-0.2/support/libspa-support.so
    #2  0x00007fffb802e646 in  () at /usr/lib/spa-0.2/support/libspa-support.so
    #3  0x00007fff8ae4f16d in  () at /usr/lib/libpipewire-0.3.so.0
    #4  0x00007ffff3eaa9eb in  () at /usr/lib/libc.so.6
    #5  0x00007ffff3f2e7cc in  () at /usr/lib/libc.so.6
    
  4. kkartaltepe commented on Oct 21, 2023

    @kkartaltepe
    Collaborator

    if your stack has #1 0x00007fff8c1841b8 in swap_texture_red_blue (texture=0x7fff6014fe20) this is a duplicate already fixed issue. Please only provide stacks from current master obs, always include the commit id you have tested on.

    And ensure your stacks have symbols and lines , stacks without debug symbols are not going to be helpful in identifying if there are any other additional issues than what was originally reported.

  5. nickc01 commented on Oct 21, 2023

    @nickc01

    I emerged the 9999 ebuild versions of obs and pipewire, and now it no longer crashes when sharing screens. However, when I go to share the screen, the red and blue channels seem to be swapped.
    obsColorsSwapped

    The obs logs says the negotiated format was Spa:Enum:VideoFormat:RGBX

    info: [pipewire] Asking for desktop
    info: [pipewire] desktop selected, setting up screencast
    info: [pipewire] Server version: 0.3.83
    info: [pipewire] Library version: 0.3.83
    info: [pipewire] Header version: 0.3.80
    info: [pipewire] Created stream 0x55632c8b1e60
    info: [pipewire] Stream 0x55632c8b1e60 state: "connecting" (error: none)
    info: [pipewire] Playing stream 0x55632c8b1e60
    info: [pipewire] Stream 0x55632c8b1e60 state: "paused" (error: none)
    info: [pipewire] Negotiated format:
    info: [pipewire]     Format: 7 (Spa:Enum:VideoFormat:RGBx)
    info: [pipewire]     Size: 2560x1440
    info: [pipewire]     Framerate: 0/1
    info: [pipewire] Stream 0x55632c8b1e60 state: "streaming" (error: none)
    

    I can create a separate issue for this, since it no longer seems relevant to the problem in this issue

  6. kkartaltepe commented on Oct 21, 2023

    @kkartaltepe
    Collaborator

    I can create a separate issue for this, since it no longer seems relevant to the problem in this issue

    Yes please create another issue for this. I already have a fix pending for this so no need for an issue.

  7. added
    platform/linux
    issue/confirmed
    on Oct 21, 2023
  8. kkartaltepe commented on Oct 21, 2023

    @kkartaltepe
    Collaborator

    I was able to replicate this.

  9. added a commit that references this issue on Oct 21, 2023
    95a7aa7
  10. removed
    issue/confirmed
    on Oct 21, 2023
  11. kkartaltepe commented on Oct 21, 2023

    @kkartaltepe
    Collaborator

    Ok actually it was probably a different issue, but if you can try the glad symbols change and see if it fixes anything that would help.

  12. nickc01 commented on Oct 23, 2023

    @nickc01

    Update

    So I tried reemerging the 9999 ebuilds of obs-studio and pipewire to test out the new commits, and I'm now getting the SEGFAULT again when selecting a monitor to share. What's interesting is that the backtrace shows that the segfault is occurring at the "swap_texture_red_blue" function. Except now it's SEGFAULTing on the 9999 builds, even though this should already be a fixed issue.

    Pipewire commit - 920beea3
    OBS Studio commit - 454fc55

    Console Log

    Details
    nick@localhost ~> sudo emerge -a obs-studio pipewire
    
    These are the packages that would be merged, in order:
    
    Calculating dependencies... done!
    Dependency resolution took 1.87 s.
    
    [ebuild   R   *] media-video/pipewire-9999 
    [ebuild   R   *] media-video/obs-studio-9999 
    
    Would you like to merge these packages? [Yes/No] Yes
    >>> Verifying ebuild manifests
    >>> Emerging (1 of 2) media-video/pipewire-9999::gentoo
    >>> Installing (1 of 2) media-video/pipewire-9999::gentoo
    >>> Completed (1 of 2) media-video/pipewire-9999::gentoo
    >>> Emerging (2 of 2) media-video/obs-studio-9999::gentoo
    >>> Installing (2 of 2) media-video/obs-studio-9999::gentoo
    >>> Completed (2 of 2) media-video/obs-studio-9999::gentoo
    >>> Jobs: 2 of 2 complete                           Load avg: 8.61, 2.85, 1.03
    
     * Messages for package media-video/pipewire-9999:
    
     * For latest tips and tricks, troubleshooting information, and documentation
     * in general, please refer to https://wiki.gentoo.org/wiki/PipeWire
     * 
    
     * Messages for package media-video/obs-studio-9999:
    
     * Install additional packages for optional runtime features:
     *   media-video/v4l2loopback for virtual camera support
    
     * GNU info directory index is up-to-date.
    nick@localhost ~> gdb obs
    GNU gdb (Gentoo 13.2 vanilla) 13.2
    Copyright (C) 2023 Free Software Foundation, Inc.
    License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    This is free software: you are free to change and redistribute it.
    There is NO WARRANTY, to the extent permitted by law.
    Type "show copying" and "show warranty" for details.
    This GDB was configured as "x86_64-pc-linux-gnu".
    Type "show configuration" for configuration details.
    For bug reporting instructions, please see:
    <https://bugs.gentoo.org/>.
    Find the GDB manual and other documentation resources online at:
        <http://www.gnu.org/software/gdb/documentation/>.
    
    For help, type "help".
    Type "apropos word" to search for commands related to "word"...
    Reading symbols from obs...
    Reading symbols from /usr/lib/debug//usr/bin/obs.debug...
    (gdb) run
    Starting program: /usr/bin/obs 
    [Thread debugging using libthread_db enabled]
    Using host libthread_db library "/lib64/libthread_db.so.1".
    [New Thread 0x7fffe21196c0 (LWP 19983)]
    [New Thread 0x7fffe19186c0 (LWP 19984)]
    [New Thread 0x7fffe11176c0 (LWP 19985)]
    [New Thread 0x7fffe09166c0 (LWP 19986)]
    [New Thread 0x7fffd3fff6c0 (LWP 19987)]
    [New Thread 0x7fffd37fe6c0 (LWP 19988)]
    debug: Found portal inhibitor
    debug: Attempted path: share/obs/obs-studio/locale/en-US.ini
    debug: Attempted path: /usr/share/obs/obs-studio/locale/en-US.ini
    debug: Attempted path: share/obs/obs-studio/locale.ini
    debug: Attempted path: /usr/share/obs/obs-studio/locale.ini
    debug: Attempted path: share/obs/obs-studio/themes
    debug: Attempted path: /usr/share/obs/obs-studio/themes
    debug: Attempted path: share/obs/obs-studio/themes/Yami.qss
    debug: Attempted path: /usr/share/obs/obs-studio/themes/Yami.qss
    info: Platform: Wayland
    info: CPU Name: AMD Ryzen 9 5950X 16-Core Processor
    info: CPU Speed: 3598.618MHz
    info: Physical Cores: 16, Logical Cores: 32
    info: Physical Memory: 31995MB Total, 27828MB Free
    info: Kernel Version: Linux 6.1.57-gentoo-dist
    info: Distribution: Gentoo "2.14"
    info: Desktop Environment: sway
    info: Session Type: wayland
    [New Thread 0x7fffd27ff6c0 (LWP 19989)]
    [New Thread 0x7fffd1ffe6c0 (LWP 19990)]
    info: Qt Version: 6.5.2 (runtime), 6.5.2 (compiled)
    info: Portable mode: false
    info: OBS 30.0.0-rc1-27-g454fc559a-modified (linux)
    info: ---------------------------------
    info: ---------------------------------
    info: audio settings reset:
    	samples per sec: 48000
    	speakers:        2
    	max buffering:   960 milliseconds
    	buffering type:  dynamically increasing
    [New Thread 0x7fffd17626c0 (LWP 19991)]
    info: ---------------------------------
    info: Initializing OpenGL...
    info: Using EGL/Wayland
    [New Thread 0x7fffd0c2d6c0 (LWP 19992)]
    [New Thread 0x7fffae7ff6c0 (LWP 19993)]
    [New Thread 0x7fffadffe6c0 (LWP 19994)]
    [New Thread 0x7fffad7fd6c0 (LWP 19995)]
    info: Initialized EGL 1.5
    [New Thread 0x7fffacdfc6c0 (LWP 19996)]
    [New Thread 0x7fff97fff6c0 (LWP 19997)]
    info: Loading up OpenGL on adapter AMD AMD Radeon RX 6750 XT (navi22, LLVM 16.0.6, DRM 3.49, 6.1.57-gentoo-dist)
    info: OpenGL loaded successfully, version 4.6 (Core Profile) Mesa 23.1.8, shading language 4.60
    info: ---------------------------------
    info: video settings reset:
    	base resolution:   2560x1440
    	output resolution: 1920x1080
    	downscale filter:  Bicubic
    	fps:               60/1
    	format:            NV12
    	YUV mode:          Rec. 709/Partial
    [New Thread 0x7fff977fe6c0 (LWP 19998)]
    info: NV12 texture support not available
    info: P010 texture support not available
    [New Thread 0x7fff95e2d6c0 (LWP 19999)]
    info: Audio monitoring device:
    	name: Default
    	id: default
    info: ---------------------------------
    [Detaching after fork from child process 20000]
    [Detaching after fork from child process 20001]
    [Detaching after fork from child process 20002]
    [Detaching after fork from child process 20003]
    [Detaching after fork from child process 20004]
    [Detaching after fork from child process 20005]
    [Detaching after fork from child process 20006]
    [Detaching after fork from child process 20007]
    [Detaching after fork from child process 20008]
    [Detaching after fork from child process 20009]
    info: [pipewire] Available captures:
    info: [pipewire]     - Desktop capture
    [Detaching after fork from child process 20010]
    [Detaching after fork from child process 20011]
    [Detaching after vfork from child process 20012]
    warning: v4l2loopback not installed, virtual camera disabled
    [Detaching after fork from child process 20013]
    info: [obs-browser]: Version 2.22.1
    info: [obs-browser]: CEF Version 103.0.5060.134 (runtime), 103.0.0-5060-shared-textures_143.2591+g4204d54+chromium-103.0.5060.134 (compiled)
    [Detaching after fork from child process 20014]
    [New Thread 0x7fff781ff6c0 (LWP 20015)]
    [New Thread 0x7fff779fe6c0 (LWP 20016)]
    [New Thread 0x7fff771fd6c0 (LWP 20017)]
    [New Thread 0x7fff769fc6c0 (LWP 20018)]
    info: VAAPI: API version 1.18
    [Thread 0x7fff769fc6c0 (LWP 20018) exited]
    [Thread 0x7fff771fd6c0 (LWP 20017) exited]
    [Thread 0x7fff779fe6c0 (LWP 20016) exited]
    [Thread 0x7fff781ff6c0 (LWP 20015) exited]
    info: FFmpeg VAAPI H264 encoding supported
    [New Thread 0x7fff781ff6c0 (LWP 20019)]
    [New Thread 0x7fff771fd6c0 (LWP 20020)]
    [New Thread 0x7fff769fc6c0 (LWP 20021)]
    [New Thread 0x7fff779fe6c0 (LWP 20022)]
    [New Thread 0x7fff761fb6c0 (LWP 20023)]
    [New Thread 0x7fff759fa6c0 (LWP 20024)]
    [Thread 0x7fff779fe6c0 (LWP 20022) exited]
    [Thread 0x7fff759fa6c0 (LWP 20024) exited]
    [Thread 0x7fff761fb6c0 (LWP 20023) exited]
    [Thread 0x7fff769fc6c0 (LWP 20021) exited]
    [Thread 0x7fff771fd6c0 (LWP 20020) exited]
    [Thread 0x7fff781ff6c0 (LWP 20019) exited]
    info: FFmpeg VAAPI HEVC encoding supported
    [Detaching after fork from child process 20025]
    [Detaching after fork from child process 20026]
    [Detaching after fork from child process 20027]
    [Detaching after fork from child process 20028]
    [Detaching after fork from child process 20029]
    [Detaching after fork from child process 20030]
    [New Thread 0x7fff781ff6c0 (LWP 20032)]
    [Detaching after fork from child process 20033]
    info: [vlc-video]: VLC 3.0.18 Vetinari found, VLC video source enabled
    info: ---------------------------------
    info:   Loaded Modules:
    info:     vlc-video.so
    info:     rtmp-services.so
    info:     obs-x264.so
    info:     obs-vst.so
    info:     obs-transitions.so
    info:     obs-outputs.so
    info:     obs-filters.so
    info:     obs-ffmpeg.so
    info:     obs-browser.so
    info:     linux-v4l2.so
    info:     linux-pulseaudio.so
    info:     linux-pipewire.so
    info:     linux-jack.so
    info:     linux-capture.so
    info:     linux-alsa.so
    info:     image-source.so
    info:     frontend-tools.so
    info: ---------------------------------
    info: ==== Startup complete ===============================================
    info: All scene data cleared
    info: ------------------------------------------------
    [New Thread 0x7fff769fc6c0 (LWP 20034)]
    info: pulse-input: Server name: 'PulseAudio (on PipeWire 0.3.83) 15.0.0'
    info: pulse-input: Audio format: s16le, 48000 Hz, 2 channels
    info: pulse-input: Started recording from 'alsa_output.usb-Cosair_Corsair_VOID_ELITE_USB_Gaming_Headset_00000000-00.analog-stereo.monitor' (default)
    info: [Loaded global audio device]: 'Desktop Audio'
    info: pulse-input: Server name: 'PulseAudio (on PipeWire 0.3.83) 15.0.0'
    info: pulse-input: Audio format: s16le, 48000 Hz, 2 channels
    info: pulse-input: Started recording from 'alsa_input.usb-Cosair_Corsair_VOID_ELITE_USB_Gaming_Headset_00000000-00.analog-stereo' (default)
    info: [Loaded global audio device]: 'Mic/Aux'
    info: PipeWire initialized
    info: Switched to scene 'Scene'
    info: ------------------------------------------------
    info: Loaded scenes:
    info: - scene 'Scene':
    info:     - source: 'Screen Capture (PipeWire)' (pipewire-desktop-capture-source)
    info: ------------------------------------------------
    info: [pipewire] Screencast session created
    [Thread 0x7fff781ff6c0 (LWP 20032) exited]
    info: adding 21 milliseconds of audio buffering, total audio buffering is now 21 milliseconds (source: Desktop Audio)
    
    info: [pipewire] Asking for desktop
    info: [pipewire] desktop selected, setting up screencast
    [New Thread 0x7fff759fa6c0 (LWP 20054)]
    [New Thread 0x7fff761fb6c0 (LWP 20055)]
    info: [pipewire] Server version: 0.3.83
    info: [pipewire] Library version: 0.3.83
    info: [pipewire] Header version: 0.3.83
    info: [pipewire] Created stream 0x555557424190
    info: [pipewire] Stream 0x555557424190 state: "connecting" (error: none)
    info: [pipewire] Playing stream 0x555557424190
    info: [pipewire] Stream 0x555557424190 state: "paused" (error: none)
    info: [pipewire] Negotiated format:
    info: [pipewire]     Format: 7 (Spa:Enum:VideoFormat:RGBx)
    info: [pipewire]     Size: 1920x1080
    info: [pipewire]     Framerate: 0/1
    info: [pipewire] Stream 0x555557424190 state: "streaming" (error: none)
    
    Thread 32 "PipeWire thread" received signal SIGSEGV, Segmentation fault.
    [Switching to Thread 0x7fff761fb6c0 (LWP 20055)]

    Backtrace

    Details
    0x0000000000000000 in ?? ()
    (gdb) bt full
    #0  0x0000000000000000 in  ()
    #1  0x00007fff952cf105 in swap_texture_red_blue (texture=0x7fff70073ba0) at /usr/src/debug/media-video/obs-studio-9999/obs-studio-9999/plugins/linux-pipewire/pipewire.c:379
            gl_texure = 7
    #2  0x00007fff952d07f9 in process_video_sync (obs_pw_stream=0x555556fc3ea0) at /usr/src/debug/media-video/obs-studio-9999/obs-studio-9999/plugins/linux-pipewire/pipewire.c:910
            obs_pw = 0x55555733b060
            cursor = 0x404057426448
            header = 0x7fffb7fb0008
            region = 0xa0
            video_transform = 0x7fff761fa4f0
            format_data = {spa_format = 7, drm_format = 875709016, gs_format = GS_BGRX, video_format = VIDEO_FORMAT_NONE, swap_red_blue = true, bpp = 4, pretty_name = 0x7fff952f33df "XBGR8888"}
            buffer = 0x7fff700e86c0
            b = 0x5555574245c8
            has_buffer = true
            __PRETTY_FUNCTION__ = "process_video_sync"
    #3  0x00007fff952d0bfd in on_process_cb (user_data=0x555556fc3ea0) at /usr/src/debug/media-video/obs-studio-9999/obs-studio-9999/plugins/linux-pipewire/pipewire.c:1004
            obs_pw_stream = 0x555556fc3ea0
            output_flags = 1
    #4  0x00007fff9430b118 in do_call_process (loop=0x5555573f7250, async=true, seq=1, data=0x5555573f7388, size=0, user_data=0x555557424190) at ../pipewire-9999/src/pipewire/stream.c:453
            _f = 0x7fff9530d540 <stream_events>
            _res = true
            _list = 0x555557424200
            _s = 0x555557424200
            _cursor = {link = {next = 0x555557424200, prev = 0x555556fc3ec0}, cb = {funcs = 0x0, data = 0x0}, removed = 0x0, priv = 0x0}
            _ci = 0x555556fc3ec0
            _count = 0
            impl = 0x555557424190
            stream = 0x555557424190
    #5  0x00007fff95325079 in flush_items (impl=0x5555573f7238) at ../pipewire-9999/spa/plugins/support/loop.c:180
            item = 0x5555573f7348
            block = false
            func = 0x7fff9430b00f <do_call_process>
            index = 0
            flush_count = 1
            avail = 64
            res = 32767
            __func__ = "flush_items"
    #6  0x00007fff9532608c in wakeup_func (data=0x5555573f7238, count=1) at ../pipewire-9999/spa/plugins/support/loop.c:319
            impl = 0x5555573f7238
    #7  0x00007fff95327f47 in source_event_func (source=0x55555739f800) at ../pipewire-9999/spa/plugins/support/loop.c:663
            s = 0x55555739f800
            count = 1
            res = 0
            __func__ = "source_event_func"
    #8  0x00007fff95326d6b in loop_iterate (object=0x5555573f7238, timeout=-1) at ../pipewire-9999/spa/plugins/support/loop.c:496
            s = 0x55555739f800
            impl = 0x5555573f7238
            ep = {{events = 1, data = 0x55555739f800}, {events = 1981786160, data = 0x7ffff41f6c80}, {events = 98112, data = 0xff40}, {events = 1461338688, data = 0x7ffff40bae7b}, {events = 16, data = 0xf40bae7b}, {events = 0, data = 0x7ffff40a9daf}, {events = 1, data = 0x189ff269400}, {events = 1459358468, data = 0x0}, {events = 1459358696, data = 0x555556fc0ad8}, {events = 0, data = 0x7ffff40ac4a9 <pthread_cond_wait+249>}, {events = 1459358696, data = 0x3}, {events = 1459358424, data = 0x555556fc0ab0}, {events = 4, data = 0x7}, {events = 1, data = 0x7fff761fa870}, {events = 4094346016, data = 0x7fff761fa890}, {events = 1459772704, data = 0x0}, {events = 7, data = 0x555556fc0ad8}, {events = 1459358384, data = 0x24a8b5ff00000000}, {events = 1947803548, data = 0x9cc2f102ff269400}, {events = 4280718336, data = 0x555556fc0aa0}, {events = 2, data = 0x7ffff40b05aa <pthread_mutex_lock+282>}, {events = 0, data = 0x7ffff40b1e5e}, {events = 1459358368, data = 0x7fff786b5516}, {events = 0, data = 0x0}, {events = 2031987712, data = 0x555557025d10}, {events = 0, data = 0x555556fc0b08}, {events = 980640367, data = 0x0}, {events = 4294967295, data = 0xffffffffffffffff}, {events = 4294967295, data = 0x7ffff40bae7b}, {events = 1981791452, data = 0x7fff94315dbc <do_lock+29>}, {events = 4294967295, data = 0x7fff953261d0 <loop_enter+25>}, {events = 4294967295, data = 0x5555573f7238}}
            e = 0x0
            i = 0
            nfds = 1
    #9  0x00007fff94317184 in do_loop (user_data=0x5555570af1a0) at ../pipewire-9999/src/pipewire/thread-loop.c:295
            _f = 0x7fff95346600 <impl_loop_control>
            _res = 1
            _o = 0x5555573f7270
            this = 0x5555570af1a0
            res = 1
            __func__ = "do_loop"
    #10 0x00007ffff40ad2b9 in  () at /lib64/libc.so.6
    #11 0x00007ffff413030c in  () at /lib64/libc.so.6
    
  13. jonhoo commented on Oct 23, 2023

    @jonhoo
    Author

    Ok actually it was probably a different issue, but if you can try the glad symbols change and see if it fixes anything that would help.

    I'm traveling for most of this week, but will give it a try once I have a chance, thanks!

  14. nickc01 commented on Oct 24, 2023

    @nickc01

    Ok actually it was probably a different issue, but if you can try the glad symbols change and see if it fixes anything that would help.

    I was able to build the kkartaltepe:pipewire-load-gl version of obs, and it seems to have fixed the crashing issue. It still had the "red and blue channels swapped" issue, but that was fixed after I applied the changes you made here #9743 (comment), which looks to already be merged into master. OBS seemed to function normally now, and I was able to record my desktop with no issues 👍
    working pipewire capture

  15. sebastian-s-beckmann commented on Oct 26, 2023

    @sebastian-s-beckmann
    Member

    @jonhoo could you retry whether this still happens on latest master (as of today)?

  16. jonhoo commented on Oct 26, 2023

    @jonhoo
    Author

    Should have a chance to test it this weekend! 👍

  17. MasterKing0806 commented on Oct 27, 2023

    @MasterKing0806

    Just tested screensharing on latest master and it did not work for me either. Obs was still crashing.

    I am on the newest Hyprland and xdg-desktop-portal-hyprland commit on Arch. Pipewire is also on the latest version from the Arch repo.

  18. jonhoo commented on Oct 28, 2023

    @jonhoo
    Author

    @jonhoo could you retry whether this still happens on latest master (as of today)?

    @gxalpha No luck with latest master (specifically ba44671) and all other dependencies fully updated:

    * thread #27, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x30)
        frame #0: 0x00007fff887c19bc linux-pipewire.so`renegotiate_format(data=0x0000555557a057e0, expirations=<unavailable>) at pipewire.c:631:2
       628
       629          blog(LOG_INFO, "[pipewire] Renegotiating stream");
       630
    -> 631          pw_thread_loop_lock(obs_pw->thread_loop);
       632
       633          uint8_t params_buffer[4096];
       634          struct spa_pod_builder pod_builder =
      thread #29, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x2d)
        frame #0: 0x00007fff887c19bc linux-pipewire.so`renegotiate_format(data=0x0000555557a35900, expirations=<unavailable>) at pipewire.c:631:2
       628
       629          blog(LOG_INFO, "[pipewire] Renegotiating stream");
       630
    -> 631          pw_thread_loop_lock(obs_pw->thread_loop);
       632
       633          uint8_t params_buffer[4096];
       634          struct spa_pod_builder pod_builder =
    (lldb) bt
    * thread #27, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x30)
      * frame #0: 0x00007fff887c19bc linux-pipewire.so`renegotiate_format(data=0x0000555557a057e0, expirations=<unavailable>) at pipewire.c:631:2
        frame #1: 0x00007fffc3e34cb9 libspa-support.so`source_event_func(source=0x000055555749ecc0) at loop.c:663:2
        frame #2: 0x00007fffc3e36646 libspa-support.so`loop_iterate(object=0x00005555574aa4f8, timeout=<unavailable>) at loop.c:496:4
        frame #3: 0x00007fff8872316d libpipewire-0.3.so.0`do_loop(user_data=0x0000555557322c30) at thread-loop.c:295:14
        frame #4: 0x00007ffff3eaa9eb libc.so.6`start_thread(arg=<unavailable>) at pthread_create.c:444:8
        frame #5: 0x00007ffff3f2e7cc libc.so.6`__clone3 at clone3.S:78
    (lldb) t 29
    * thread #29, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x2d)
        frame #0: 0x00007fff887c19bc linux-pipewire.so`renegotiate_format(data=0x0000555557a35900, expirations=<unavailable>) at pipewire.c:631:2
       628
       629          blog(LOG_INFO, "[pipewire] Renegotiating stream");
       630
    -> 631          pw_thread_loop_lock(obs_pw->thread_loop);
       632
       633          uint8_t params_buffer[4096];
       634          struct spa_pod_builder pod_builder =
    (lldb) bt
    * thread #29, name = 'PipeWire thread', stop reason = signal SIGSEGV: invalid address (fault address: 0x2d)
      * frame #0: 0x00007fff887c19bc linux-pipewire.so`renegotiate_format(data=0x0000555557a35900, expirations=<unavailable>) at pipewire.c:631:2
        frame #1: 0x00007fffc3e34cb9 libspa-support.so`source_event_func(source=0x000055555750ce90) at loop.c:663:2
        frame #2: 0x00007fffc3e36646 libspa-support.so`loop_iterate(object=0x00005555574dc858, timeout=<unavailable>) at loop.c:496:4
        frame #3: 0x00007fff8872316d libpipewire-0.3.so.0`do_loop(user_data=0x00005555574dc690) at thread-loop.c:295:14
        frame #4: 0x00007ffff3eaa9eb libc.so.6`start_thread(arg=<unavailable>) at pthread_create.c:444:8
        frame #5: 0x00007ffff3f2e7cc libc.so.6`__clone3 at clone3.S:78
    

    Log: obs.log

  19. added 3 commits that reference this issue on Oct 28, 2023
    99fdc9b
    3cc1feb
    a7b5357
  20. added a commit that references this issue on Oct 28, 2023
    658657d
  21. added a commit that references this issue on Oct 28, 2023
    18dd416
  22. jonhoo commented on Oct 29, 2023

    @jonhoo
    Author

    Yep, can confirm that this was fixed by #9774 🎉
    Thanks all!

  23. added a commit that references this issue on Aug 22, 2026
    b8b5087
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    platform/linux

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions