aboutsummaryrefslogtreecommitdiffstats
path: root/src/song.c
diff options
context:
space:
mode:
authorWarren Dukes <warren.dukes@gmail.com>2004-06-02 02:07:07 +0000
committerWarren Dukes <warren.dukes@gmail.com>2004-06-02 02:07:07 +0000
commit3c0c34bcb73ac7fa761b5b685f367512bb466b97 (patch)
treeb4161d3eba175dcccaf8341c58b1b114f6eaab97 /src/song.c
parent48dce62e4f79c125df24f15a6d0fe5a5e1bc19d2 (diff)
downloadmpd-3c0c34bcb73ac7fa761b5b685f367512bb466b97.tar.gz
mpd-3c0c34bcb73ac7fa761b5b685f367512bb466b97.tar.xz
mpd-3c0c34bcb73ac7fa761b5b685f367512bb466b97.zip
'\n' are bad
git-svn-id: https://svn.musicpd.org/mpd/trunk@1296 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r--src/song.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/song.c b/src/song.c
index c1f465177..ed88f1f60 100644
--- a/src/song.c
+++ b/src/song.c
@@ -51,7 +51,11 @@ Song * newNullSong() {
}
Song * newSong(char * utf8url, SONG_TYPE type) {
- Song * song = newNullSong();
+ Song * song = NULL;
+
+ if(strchr(utf8url, '\n')) return NULL;
+
+ song = newNullSong();
song->utf8url = strdup(utf8url);
song->type = type;