aboutsummaryrefslogtreecommitdiffstats
path: root/src/song_save.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-08 11:05:25 +0200
committerMax Kellermann <max@duempel.org>2008-10-08 11:05:25 +0200
commit5e4be9e495677a6728e3161e39a05a081a5bff9a (patch)
treecbcf94a5d1c9236e5fff17f21cbd9e3f0557a574 /src/song_save.c
parent4a510a26744a78696f0c69713bf3b05881175fef (diff)
downloadmpd-5e4be9e495677a6728e3161e39a05a081a5bff9a.tar.gz
mpd-5e4be9e495677a6728e3161e39a05a081a5bff9a.tar.xz
mpd-5e4be9e495677a6728e3161e39a05a081a5bff9a.zip
song: replaced all song constructors
Provide separate constructors for creating a remote song, a local song, and one for loading data from a song file. This way, we can add more assertions.
Diffstat (limited to '')
-rw-r--r--src/song_save.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/song_save.c b/src/song_save.c
index 00e4a8580..976a97afd 100644
--- a/src/song_save.c
+++ b/src/song_save.c
@@ -113,8 +113,8 @@ void readSongInfoIntoList(FILE *fp, struct songvec *sv,
if (song)
insertSongIntoList(sv, song);
- song = song_alloc(buffer + strlen(SONG_KEY),
- parentDir);
+ song = song_file_new(buffer + strlen(SONG_KEY),
+ parentDir);
} else if (*buffer == 0) {
/* ignore empty lines (starting with '\0') */
} else if (song == NULL) {