output/Control: GetName() returns std::string&
This commit is contained in:
parent
e74788ea32
commit
8a0ba7a725
@ -269,8 +269,8 @@ public:
|
|||||||
AudioOutputControl &operator=(const AudioOutputControl &) = delete;
|
AudioOutputControl &operator=(const AudioOutputControl &) = delete;
|
||||||
|
|
||||||
[[gnu::pure]]
|
[[gnu::pure]]
|
||||||
const char *GetName() const noexcept {
|
const auto &GetName() const noexcept {
|
||||||
return name.c_str();
|
return name;
|
||||||
}
|
}
|
||||||
|
|
||||||
[[gnu::pure]]
|
[[gnu::pure]]
|
||||||
|
@ -100,7 +100,8 @@ MultipleOutputs::Configure(EventLoop &event_loop, EventLoop &rt_event_loop,
|
|||||||
&filter_factory);
|
&filter_factory);
|
||||||
if (HasName(output->GetName()))
|
if (HasName(output->GetName()))
|
||||||
throw FormatRuntimeError("output devices with identical "
|
throw FormatRuntimeError("output devices with identical "
|
||||||
"names: %s", output->GetName());
|
"names: %s",
|
||||||
|
output->GetName().c_str());
|
||||||
|
|
||||||
outputs.emplace_back(std::move(output));
|
outputs.emplace_back(std::move(output));
|
||||||
});
|
});
|
||||||
|
@ -421,7 +421,7 @@ AudioOutputControl::InternalDrain() noexcept
|
|||||||
void
|
void
|
||||||
AudioOutputControl::Task() noexcept
|
AudioOutputControl::Task() noexcept
|
||||||
{
|
{
|
||||||
FormatThreadName("output:%s", GetName());
|
FormatThreadName("output:%s", GetName().c_str());
|
||||||
|
|
||||||
try {
|
try {
|
||||||
SetThreadRealtime();
|
SetThreadRealtime();
|
||||||
|
Loading…
Reference in New Issue
Block a user