Source code

Revision control

Copy as Markdown

Other Tools

From: Jan Grulich <jgrulich@redhat.com>
Date: Wed, 4 Sep 2024 13:43:00 +0000
Subject: Bug 1830275 - WebRTC backport: PipeWire camera: make member variable
with the PipeWire status updated r=pehrsons,webrtc-reviewers
We keep information about the PipeWire camera status as a member of the
PipeWire session, but it's never updated and remains in uninitialized
state. Make sure it gets updated once PipeWire is initialized or when it
fails. There is currently no use for this member variable, but there is
a plan to use it so I'm rather keeping it instead of removing it.
This is a simple backport of an WebRTC upstream change.
Upstream commit: 3881cb65cfcec90b6f0a56ce7223a471aa0115f2
---
modules/video_capture/linux/pipewire_session.cc | 2 ++
1 file changed, 2 insertions(+)
diff --git a/modules/video_capture/linux/pipewire_session.cc b/modules/video_capture/linux/pipewire_session.cc
index fd93b31063..e17e28a65f 100644
--- a/modules/video_capture/linux/pipewire_session.cc
+++ b/modules/video_capture/linux/pipewire_session.cc
@@ -422,6 +422,8 @@ void PipeWireSession::OnRegistryGlobalRemove(void* data, uint32_t id) {
}
void PipeWireSession::Finish(VideoCaptureOptions::Status status) {
+ status_ = status;
+
webrtc::MutexLock lock(&callback_lock_);
if (callback_) {