From d7838950d8866127bab5072532fa6e438728c9c1 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 7 Sep 2020 20:02:50 +0200 Subject: test/run_input: use WithBufferedOutputStream() --- test/dump_playlist.cxx | 6 +++--- test/run_input.cxx | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'test') diff --git a/test/dump_playlist.cxx b/test/dump_playlist.cxx index ea3be3a3f..ba973703b 100644 --- a/test/dump_playlist.cxx +++ b/test/dump_playlist.cxx @@ -41,9 +41,9 @@ static void tag_save(FILE *file, const Tag &tag) { StdioOutputStream sos(file); - BufferedOutputStream bos(sos); - tag_save(bos, tag); - bos.Flush(); + WithBufferedOutputStream(sos, [&](auto &bos){ + tag_save(bos, tag); + }); } int main(int argc, char **argv) diff --git a/test/run_input.cxx b/test/run_input.cxx index d5648f11a..4c067fb45 100644 --- a/test/run_input.cxx +++ b/test/run_input.cxx @@ -124,9 +124,9 @@ static void tag_save(FILE *file, const Tag &tag) { StdioOutputStream sos(file); - BufferedOutputStream bos(sos); - tag_save(bos, tag); - bos.Flush(); + WithBufferedOutputStream(sos, [&](auto &bos){ + tag_save(bos, tag); + }); } static int -- cgit v1.2.3