aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder_thread.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-04 19:09:34 +0100
committerMax Kellermann <max@duempel.org>2009-01-04 19:09:34 +0100
commitfed719197c7014151710c4aae9174990fd131d59 (patch)
tree0fb6d6f69aa60ecdf9eb89286f8354316fffcc92 /src/decoder_thread.c
parentea8ae68e6f1a686fd96530fdaf7b428e33f58ec4 (diff)
downloadmpd-fed719197c7014151710c4aae9174990fd131d59.tar.gz
mpd-fed719197c7014151710c4aae9174990fd131d59.tar.xz
mpd-fed719197c7014151710c4aae9174990fd131d59.zip
song: allocate the result of song_get_url()
Diffstat (limited to 'src/decoder_thread.c')
-rw-r--r--src/decoder_thread.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/decoder_thread.c b/src/decoder_thread.c
index 061048d94..a856c1f00 100644
--- a/src/decoder_thread.c
+++ b/src/decoder_thread.c
@@ -208,11 +208,8 @@ static void decoder_run(void)
if (song_is_file(song))
uri = map_song_fs(song);
- else {
- char buffer[MPD_PATH_MAX];
-
- uri = g_strdup(song_get_url(song, buffer));
- }
+ else
+ uri = song_get_uri(song);
if (uri == NULL) {
dc.state = DECODE_STATE_ERROR;