aboutsummaryrefslogtreecommitdiffstats
path: root/src/decode.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/decode.c')
-rw-r--r--src/decode.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/decode.c b/src/decode.c
index 55252c46e..a02dfe063 100644
--- a/src/decode.c
+++ b/src/decode.c
@@ -159,9 +159,7 @@ int waitOnDecode(PlayerControl * pc, DecoderControl * dc, OutputBuffer * cb,
if((tag = metadataChunkToMpdTagDup(&(pc->fileMetadataChunk)))) {
sendMetdataToAudioDevice(tag);
- printMpdTag(stdout, tag);
freeMpdTag(tag);
- tag = NULL;
}
pc->totalTime = pc->fileTime;
@@ -428,7 +426,15 @@ void handleMetadata(OutputBuffer * cb, PlayerControl * pc, int * previous,
if(!(*currentChunkSent) && pc->metadataState ==
PLAYER_METADATA_STATE_WRITE)
{
+ MpdTag * tag = NULL;
+
*currentChunkSent = 1;
+
+ if((tag = metadataChunkToMpdTagDup(currentChunk))) {
+ sendMetdataToAudioDevice(tag);
+ freeMpdTag(tag);
+ }
+
memcpy(&(pc->metadataChunk), currentChunk,
sizeof(MetadataChunk));
pc->metadataState = PLAYER_METADATA_STATE_READ;