OBS Studio crashes when adding 2 pipewire sources to a scene

I run OBS Studio on Ubuntu 22.04.
Whenever I try to add a second window/screen source to the same scene, the program crashes when I press the green button ‘share’, with the error messages:

unable to lock lockfile '/run/user/1000/snap.obs-studio/pipewire-0.lock': Resource temporarily unavailable (maybe another daemon is running)
could not load mandatory module "libpipewire-module-protocol-native": Resource temporarily unavailable

So I cannot, for example, show two maximized windows side-by-side.
Full crash message.

Read more here: Source link