aboutsummaryrefslogtreecommitdiffstats
path: root/alc/backends/pipewire.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2021-09-14 15:09:58 -0700
committerChris Robinson <[email protected]>2021-09-14 15:09:58 -0700
commit52bfe430a332e8279381f90b5a202af580d0b912 (patch)
tree86911071a15a90c562db6ef1a6865512ceeb65e7 /alc/backends/pipewire.cpp
parent302d662c0a597fe328b5c81492103e34f208c38a (diff)
Replace a hardcoded offset value
Diffstat (limited to 'alc/backends/pipewire.cpp')
-rw-r--r--alc/backends/pipewire.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/alc/backends/pipewire.cpp b/alc/backends/pipewire.cpp
index a56e05b9..e25559d7 100644
--- a/alc/backends/pipewire.cpp
+++ b/alc/backends/pipewire.cpp
@@ -1523,7 +1523,7 @@ void PipeWireCapture::open(const char *name)
auto match = std::find_if(DeviceList.cbegin(), DeviceList.cend(), match_name);
if(match == DeviceList.cend() && std::strncmp(name, MonitorPrefix, MonitorPrefixLen) == 0)
{
- const char *sinkname{name + 11};
+ const char *sinkname{name + MonitorPrefixLen};
auto match_sinkname = [sinkname](const DeviceNode &n) -> bool
{ return !n.mCapture && n.mName == sinkname; };
match = std::find_if(DeviceList.cbegin(), DeviceList.cend(), match_sinkname);