1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 14:57:35 +00:00

LibAudio: Use Encoder interface for WavWriter

The only real change here is the fallibility of the finalization
function, which makes WavWriter's code quite a bit nicer.
This commit is contained in:
kleines Filmröllchen 2023-06-30 20:02:49 +02:00 committed by Andrew Kaster
parent 513e000e86
commit ae039977d1
4 changed files with 12 additions and 15 deletions

View file

@ -141,7 +141,7 @@ ErrorOr<void> AudioPlayerLoop::write_wav_if_needed()
m_wav_percent_written.store(100);
m_track_manager.reset();
m_track_manager.set_should_loop(true);
wav_writer.finalize();
TRY(wav_writer.finalize());
return {};
}));