aboutsummaryrefslogtreecommitdiffstats
path: root/src/SongSave.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-01-03 10:16:05 +0100
committerMax Kellermann <max@duempel.org>2013-01-03 10:16:05 +0100
commit90fe4c5124e3fd335f05804d3cc47ba996e62b14 (patch)
treeef7fb6b3cb2edbe4898431db611f04fb281129fc /src/SongSave.cxx
parent2452447c814048ed72e95a459c76b4be65962b5c (diff)
downloadmpd-90fe4c5124e3fd335f05804d3cc47ba996e62b14.tar.gz
mpd-90fe4c5124e3fd335f05804d3cc47ba996e62b14.tar.xz
mpd-90fe4c5124e3fd335f05804d3cc47ba996e62b14.zip
TextFile: convert to a class
Diffstat (limited to '')
-rw-r--r--src/SongSave.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/SongSave.cxx b/src/SongSave.cxx
index cbc2536b1..a32b7fecc 100644
--- a/src/SongSave.cxx
+++ b/src/SongSave.cxx
@@ -63,8 +63,8 @@ song_save(FILE *fp, const struct song *song)
}
struct song *
-song_load(FILE *fp, Directory *parent, const char *uri,
- GString *buffer, GError **error_r)
+song_load(TextFile &file, Directory *parent, const char *uri,
+ GError **error_r)
{
struct song *song = parent != NULL
? song_file_new(uri, parent)
@@ -73,7 +73,7 @@ song_load(FILE *fp, Directory *parent, const char *uri,
enum tag_type type;
const char *value;
- while ((line = read_text_line(fp, buffer)) != NULL &&
+ while ((line = file.ReadLine()) != NULL &&
strcmp(line, SONG_END) != 0) {
colon = strchr(line, ':');
if (colon == NULL || colon == line) {