aboutsummaryrefslogtreecommitdiffstats
path: root/src/TagSave.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-07-30 20:58:14 +0200
committerMax Kellermann <max@duempel.org>2014-07-30 22:17:01 +0200
commit9fb351a139a56fc7b1ece549894f8fc31fa887cd (patch)
tree7c9ce42a1262af587f1b9fede2b24ff39cef93fc /src/TagSave.cxx
parent0d0ccacdf3e154b1cc27a0840fce80ac13f9641c (diff)
downloadmpd-9fb351a139a56fc7b1ece549894f8fc31fa887cd.tar.gz
mpd-9fb351a139a56fc7b1ece549894f8fc31fa887cd.tar.xz
mpd-9fb351a139a56fc7b1ece549894f8fc31fa887cd.zip
*Save, *State: use the OutputStream API instead of FILE*
Diffstat (limited to 'src/TagSave.cxx')
-rw-r--r--src/TagSave.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/TagSave.cxx b/src/TagSave.cxx
index 7666287af..6ec562ec5 100644
--- a/src/TagSave.cxx
+++ b/src/TagSave.cxx
@@ -20,19 +20,19 @@
#include "config.h"
#include "TagSave.hxx"
#include "tag/Tag.hxx"
+#include "fs/output/BufferedOutputStream.hxx"
#define SONG_TIME "Time: "
void
-tag_save(FILE *file, const Tag &tag)
+tag_save(BufferedOutputStream &os, const Tag &tag)
{
if (tag.time >= 0)
- fprintf(file, SONG_TIME "%i\n", tag.time);
+ os.Format(SONG_TIME "%i\n", tag.time);
if (tag.has_playlist)
- fprintf(file, "Playlist: yes\n");
+ os.Format("Playlist: yes\n");
for (const auto &i : tag)
- fprintf(file, "%s: %s\n",
- tag_item_names[i.type], i.value);
+ os.Format("%s: %s\n", tag_item_names[i.type], i.value);
}