From 2c1f5365ebbd7ffd9ffa660a39ebc052ef96e4d2 Mon Sep 17 00:00:00 2001 From: Warren Dukes Date: Mon, 31 May 2004 14:30:54 +0000 Subject: little tidying up that will be deleted anyway git-svn-id: https://svn.musicpd.org/mpd/trunk@1260 09075e82-0dd4-0310-85a5-a0d7c8717e4f --- src/player.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/player.c b/src/player.c index dac7b59a4..e0d8ee93f 100644 --- a/src/player.c +++ b/src/player.c @@ -465,10 +465,9 @@ Song * playerCurrentDecodeSong() { DecoderControl * dc = &(getPlayerData()->decoderControl); if(dc->metadataSet && (!song || strcmp(song->utf8url, dc->utf8url))) { - if(!song) { - song = newNullSong(); - song->tag = newMpdTag(); - } + if(song) freeJustSong(song); + song = newNullSong(); + song->tag = newMpdTag(); if(song->utf8url) free(song->utf8url); song->utf8url = strdup(dc->utf8url); if(dc->title >= 0) { -- cgit v1.2.3