Skip to content

Commit

Permalink
filter/two: use if with initializer
Browse files Browse the repository at this point in the history
  • Loading branch information
MaxKellermann committed Nov 2, 2024
1 parent fc5d258 commit 0676ab7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/filter/plugins/TwoFilters.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ TwoFilters::FilterPCM(std::span<const std::byte> src)
std::span<const std::byte>
TwoFilters::Flush()
{
auto result = first->Flush();
if (result.data() != nullptr)
if (auto result = first->Flush(); result.data() != nullptr)
/* Flush() output from the first Filter must be
filtered by the second Filter */
return second->FilterPCM(result);
Expand Down

0 comments on commit 0676ab7

Please sign in to comment.